Work order processing method and apparatus, computer device, and readable storage medium
Patent Information
- Application Number
- CN202610889998.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-18
- Publication Date
- 2026-10-13
AI Technical Summary
[0003]传统技术中,可以采用人工方式处理工单,然而,由于人工判断主观性强、且易受疲劳影响,使得工单处理准确性不高
[0043]上述工单处理方法、装置、计算机设备、计算机可读存储介质和计算机程序产品,通过获取电力客服工单集,电力客服工单集包括多个工单内容,并基于多个工单内容各自的文本长度,得到各个工单内容各自对应的更新内容,从而,可以根据工单内容的文本长度,对工单内容进行差异化处理,为后续相似度分析提供长度适配的输入基础,能够有效克服人工判断的主观偏差与疲劳导致的误判,提升工单处理的准确性。通过对各个更新内容进行分组,得到至少一个待处理组,待处理组中更新内容的工单标识相同,并针对各个待处理组,基于与待处理组的文本长度适配的工单相似度计算策略,确定待处理组中各个更新内容之间的第一相似度,从而,能够针对待处理组中同一工单标识下的多个更新内容,根据其整体文本长度自动匹配最合适的相似度计算策略,实现组内诉求的精准相似度比对,有助于提高工单重复诉求识别的准确率和处理效率。通过基于各个待处理组各自对应的各个第一相似度,得到电力客服工单集的工单处理结果,从而,在人工处理效率低、易出错的情况下,能够自动、客观地输出工单处理结果,提高了工单处理效率。
Smart Images

Figure CN122904875A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of intelligent processing technology for power customer service, and in particular to a work order processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Technology
[0002] Electricity customer service handles a large number of user updates every day. Automatically identifying hot issues and abnormal requests in work orders is key to improving service quality and optimizing resource allocation, while automatically identifying similar or duplicate requests is one of the key technologies to improve service efficiency.
[0003] In traditional technology, work orders can be processed manually. However, due to the strong subjectivity of human judgment and the susceptibility to fatigue, the accuracy of work order processing is not high. Summary of the Invention
[0004] Therefore, it is necessary to provide a work order processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the accuracy of work order processing in response to the above-mentioned technical problems.
[0005] Firstly, this application provides a work order processing method, including:
[0006] Obtain a set of electricity customer service work orders; the set of electricity customer service work orders includes multiple work order contents;
[0007] Based on the text length of each of the multiple work order contents, the update content corresponding to each of the work order contents is obtained;
[0008] Each of the updated content items is grouped to obtain at least one pending group; the work order identifiers of each of the updated content items in the pending group are the same;
[0009] For each of the pending groups, a first similarity between each of the updated contents in the pending group is determined based on a work order similarity calculation strategy adapted to the text length of the pending group.
[0010] Based on the first similarity corresponding to each of the groups to be processed, the processing result of the power customer service work order set is obtained.
[0011] In one embodiment, obtaining the updated content corresponding to each of the plurality of work order contents based on their respective text lengths includes:
[0012] Obtain the preset toneless pinyin string corresponding to each candidate word in the preset power industry thesaurus;
[0013] For each work order content, if the text length of the work order content is less than or equal to a first threshold, a target pinyin string that matches each of the preset pinyin strings is determined from the first pinyin string without tone corresponding to the work order content.
[0014] Determine the edit distance between the target pinyin string and each of the preset pinyin strings without tone marks;
[0015] If the minimum edit distance among the various edit distances is less than or equal to a preset error correction threshold, the content corresponding to the target pinyin string in the work order content is updated based on the candidate word to which the preset toneless pinyin string to which the minimum edit distance belongs, so as to obtain the updated content of the work order content.
[0016] If the minimum edit distance among the various edit distances is greater than the preset error correction threshold, the updated content corresponding to the work order content is obtained; the updated content is the same as the work order content.
[0017] In one embodiment, determining the first similarity between each of the updated contents in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group includes:
[0018] When the work order similarity calculation strategy that is adapted to the text length of the group to be processed is the first similarity calculation strategy, the second toneless pinyin string corresponding to each of the updated contents in the group to be processed is determined; the text length of the group to be processed is less than or equal to the second threshold.
[0019] Based on the similarity between each of the second toneless pinyin strings, the first similarity between each of the updated contents in the group to be processed is obtained.
[0020] In one embodiment, determining the first similarity between each of the updated contents in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group includes:
[0021] From multiple preset similarity calculation models, at least two similarity calculation models are determined;
[0022] When the work order similarity calculation strategy adapted to the text length of the group to be processed is the second similarity calculation strategy, the first similarity between each of the updated contents in the group to be processed is determined based on the at least two similarity calculation models; the text length of the group to be processed is greater than the second threshold.
[0023] In one embodiment, obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the respective groups to be processed includes:
[0024] For each of the groups to be processed, a work order duplication threshold matching the group to be processed is determined based on each of the first similarities corresponding to the group to be processed.
[0025] When the business rules configured for the power customer service work order set include time window rules, obtain the first historical cluster identifiers of multiple first historical work order contents that are located before the current time and match the work order identifier of the pending group and the time window rules.
[0026] When the updated content in the pending group is sorted according to the request time, if the similarity between the updated content and the first historical work order content is greater than or equal to the work order duplication determination threshold, the first historical cluster identifier of the first historical work order content is determined as the problem cluster identifier of the updated content.
[0027] By combining the problem cluster identifier and the work order duplicate identifier of the updated content, the content attributes of the updated content are obtained;
[0028] Based on the content attributes of each updated content in each of the pending groups, the work order processing result of the power customer service work order set is obtained.
[0029] In one embodiment, the method further includes:
[0030] Obtain the word segmentation sequence corresponding to the content of each of the multiple first historical work orders;
[0031] For each piece of the first historical work order content, determine the word vectors corresponding to the word segmentation sequence corresponding to the first historical work order content;
[0032] The average vector among the word vectors is reduced in dimensionality to obtain the low-dimensional vector corresponding to the content of the first historical work order.
[0033] Clustering is performed on the low-dimensional vectors corresponding to each of the first historical work order contents to obtain the first historical cluster identifiers to which each of the multiple first historical work order contents belongs.
[0034] Secondly, this application also provides a work order processing device, comprising:
[0035] The acquisition module is used to acquire a set of power customer service work orders; the set of power customer service work orders includes multiple work order contents.
[0036] The analysis module is used to obtain the update content corresponding to each of the multiple work order contents based on their respective text lengths.
[0037] A segmentation module is used to group the various updated contents to obtain at least one pending group; the work order identifiers of the various updated contents in the pending group are the same;
[0038] The first processing module is used to determine the first similarity between each updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group.
[0039] The second processing module is used to obtain the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the respective groups to be processed.
[0040] Thirdly, this application also provides a computer device, including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to perform the following steps: obtaining a set of power customer service work orders; the set of power customer service work orders includes multiple work order contents; based on the text length of each of the multiple work order contents, obtaining updated content corresponding to each of the work order contents; grouping the updated content into at least one pending group; the work order identifiers of the updated content in the pending group are the same; for each pending group, determining a first similarity between the updated content in the pending group based on a work order similarity calculation strategy adapted to the text length of the pending group; and obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the pending groups.
[0041] Fourthly, this application also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, performs the following steps: obtaining a set of power customer service work orders; the set of power customer service work orders includes multiple work order contents; obtaining updated content corresponding to each of the multiple work order contents based on their respective text lengths; grouping the updated content into at least one processing group; the work order identifiers of the updated content in the processing group are the same; for each processing group, determining a first similarity between the updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group; and obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each processing group.
[0042] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps: acquiring a set of power customer service work orders; the set of power customer service work orders includes multiple work order contents; obtaining updated content corresponding to each of the multiple work order contents based on their respective text lengths; grouping the updated content into at least one pending group; the work order identifiers of the updated content in the pending group being the same; for each pending group, determining a first similarity between the updated content in the pending group based on a work order similarity calculation strategy adapted to the text length of the pending group; and obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the pending groups.
[0043] The aforementioned work order processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product acquire a set of power customer service work orders, which includes multiple work order contents. Based on the text length of each work order content, they obtain the corresponding updated content for each work order content. This allows for differentiated processing of work order contents based on their text length, providing a length-adapted input basis for subsequent similarity analysis. This effectively overcomes subjective bias and fatigue-induced misjudgments caused by manual judgment, improving the accuracy of work order processing. By grouping the updated content into at least one processing group, where the updated content in the processing group shares the same work order identifier, and for each processing group, a work order similarity calculation strategy adapted to the text length of the processing group is used to determine the first similarity between the updated content in that group. This enables the automatic matching of the most suitable similarity calculation strategy based on the overall text length for multiple updated content under the same work order identifier within a processing group, achieving accurate similarity comparison of requests within the group. This helps improve the accuracy and processing efficiency of identifying duplicate work order requests. By using the first similarity scores corresponding to each group to be processed, the work order processing results of the power customer service work order set are obtained. Thus, in the case of low efficiency and error-prone manual processing, the work order processing results can be automatically and objectively output, thereby improving the efficiency of work order processing. Attached Figure Description
[0044] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0045] Figure 1 This is a flowchart illustrating a work order processing method in one embodiment;
[0046] Figure 2 This is a flowchart illustrating the process of obtaining the updated content corresponding to each work order based on the text length of each work order content in one embodiment.
[0047] Figure 3 This is a flowchart illustrating the process of determining the first similarity between each updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group in one embodiment.
[0048] Figure 4 In one embodiment, the identifier of the first historical cluster to which the contents of multiple first historical work orders belong is obtained;
[0049] Figure 5 This is a flowchart illustrating the work order processing method in another embodiment;
[0050] Figure 6 This is a structural block diagram of a work order processing device in one embodiment;
[0051] Figure 7 This is an internal structural diagram of a computer device in one embodiment;
[0052] Figure 8 This is a diagram of the internal structure of a computer device in another embodiment. Detailed Implementation
[0053] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0054] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various levels of similarity, but these similarities are not limited by these terms. These terms are only used to distinguish between the first and second similarities. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the schemes, or any combination of multiple schemes.
[0055] With the continuous development of work order processing technology, similarity calculation models can be used to determine the similarity between work orders, and then the work orders can be processed based on this similarity, i.e., determining and classifying whether a work order is a duplicate request. Typically, the same similarity calculation model is used for all work orders. However, for short text work orders (such as "power outage" or "power not yet restored"), due to the limited amount of text information, complex similarity calculation models (such as DistilBERT) struggle to extract effective semantic features and may even introduce noise, leading to inaccurate similarity calculation results. At the same time, calling similarity calculation models such as BERT consumes significant computational resources, affecting overall processing efficiency.
[0056] Based on this, this application provides a work order processing method, which can be applied to computer equipment, which can be a terminal or a server. The terminal can be, but is not limited to, various personal computers, laptops, smartphones, tablets, drones, low-altitude aircraft, IoT devices, and portable wearable devices. IoT devices can be smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, projection equipment, etc. Portable wearable devices can be smartwatches, smart bracelets, head-mounted devices, etc. Head-mounted devices can be virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc. The server can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.
[0057] In one exemplary embodiment, such as Figure 1 As shown, a work order processing method is provided. Taking the application of this method to computer equipment as an example, it includes the following steps:
[0058] S102, obtain the power customer service work order set; the power customer service work order set includes multiple work order contents.
[0059] The power customer service work order set refers to the collection of user call content received through various channels, including but not limited to telephone, online customer service, and public accounts. Work order content refers to the original text information describing the specific problem, need, or feedback submitted by the user.
[0060] For example, a power customer service work order set can also include work order identifiers and request times for each of the multiple work order items. The work order identifier is a key field used to uniquely identify the user to whom the work order belongs. For example, the work order identifier can be represented by any of the following: user terminal number, electricity account number, ID card number, etc. The request time refers to the specific time when the user submitted the work order.
[0061] In an optional embodiment, the computer device is communicatively connected to a work order processing system, the work order processing system is configured with a graphical operation interface, and the graphical operation interface includes a start processing button. Acquiring the power customer service work order set includes: in a case where the power customer service work order set has been configured through the graphical operation interface, the computer device acquires the power customer service work order set in response to a trigger event for the start processing button. Thus, the pre-configured work order set is automatically acquired through one-click triggering, which realizes rapid startup and automatic scheduling of the power customer service work order processing flow, and improves operation convenience and overall processing efficiency.
[0062] In an optional embodiment, the graphical operation interface further includes a stop button. The method further includes: in response to a trigger event for the stop button, the computer device stops the processing process for the power customer service work order set. Thus, by providing manual stop control capability, the user interactivity and operation flexibility of the power customer service work order processing process are enhanced, and unnecessary consumption of computing resources is effectively avoided.
[0063] S104: Based on the respective text lengths of the plurality of work order contents, the update content corresponding to each work order content is obtained.
[0064] The update content corresponding to the work order content may be content identical to the work order content. Alternatively, the update content corresponding to the work order content may be content obtained by updating the work order content.
[0065] It can be understood that, in an actual application scenario, if at least one of pinyin errors, homophone typos and the like exists in the work order content, for example, cases such as "tiaozha le" (which should be "triped the switch") and "dianfei" (which should be "electricity fee"), such cases will affect the subsequent processing flow and lead to inaccurate work order processing results. Therefore, updating the work order content with errors helps to improve the accuracy of work order processing.
[0066] S106: Group the respective update contents to obtain at least one to-be-processed group, wherein the work order identifiers of the respective update contents in the to-be-processed group are the same.
[0067] Specifically, according to the work order identifier to which each update content respectively belongs, the update contents with the same work order identifier are divided into one group, so as to obtain at least one to-be-processed group.
[0068] For example, taking the work order identifier as a user terminal number as an example, the groupby method of pandas is used to group the respective update contents to obtain at least one to-be-processed group.
[0069] S108: For each to-be-processed group, a first similarity between the respective update contents in the to-be-processed group is determined based on a work order similarity calculation strategy adapted to the text length of the to-be-processed group.
[0070] In an optional embodiment, determining a work order similarity calculation strategy that matches the text length of the group to be processed includes: obtaining a preset mapping relationship between the text group length and a preset similarity strategy; and determining a work order similarity calculation strategy that matches the text length of the group to be processed from the mapping relationship. Thus, by setting this mapping relationship, a suitable similarity calculation strategy can be automatically selected based on the text length of different groups to be processed, improving the accuracy of work order processing while ensuring computational efficiency.
[0071] S110, based on the first similarity of each group to be processed, the work order processing results of the power customer service work order set are obtained.
[0072] In an optional embodiment, the work order processing result of the power customer service work order set is obtained based on the first similarity corresponding to each of the groups to be processed, including: for each group to be processed, determining the content attributes of each updated content in the group to be processed based on the first similarity corresponding to the group to be processed; and obtaining the work order processing result of the power customer service work order set based on the content attributes of each updated content in each group to be processed.
[0073] The content attributes of the updated content refer to the tags assigned to the updated content to identify its processing status. For example, content attributes include, but are not limited to, work order duplicate identifiers and work order non-duplicate identifiers. A work order duplicate identifier indicates that the work order content corresponding to the updated content is a duplicate work order, meaning the work order content is a duplicate request. A work order non-duplicate identifier indicates that the work order content corresponding to the updated content is a non-duplicate work order.
[0074] In the above embodiments, by acquiring a set of power customer service work orders, which includes multiple work order contents, and based on the text length of each work order content, the corresponding updated content for each work order content is obtained. This allows for differentiated processing of the work order content based on its text length, providing a length-adapted input basis for subsequent similarity analysis. This effectively overcomes subjective bias and misjudgment caused by human judgment fatigue, improving the accuracy of work order processing. By grouping the updated content into at least one processing group, where the updated content in the processing group shares the same work order identifier, and for each processing group, a work order similarity calculation strategy adapted to the text length of the processing group is used to determine the first similarity between the updated content in that group. This allows for the automatic matching of the most suitable similarity calculation strategy based on the overall text length of multiple updated content under the same work order identifier in the processing group, achieving accurate similarity comparison of requests within the group. This helps improve the accuracy and processing efficiency of identifying duplicate requests in work orders. By using the first similarity scores corresponding to each group to be processed, the work order processing results of the power customer service work order set are obtained. Thus, in the case of low efficiency and error-prone manual processing, the work order processing results can be automatically and objectively output, thereby improving the efficiency of work order processing.
[0075] In an optional embodiment, the method further includes: when an external system calls the processing logic corresponding to the work order processing method through a command-line batch processing interface, based on the parameters input in the command line (such as the file path and time window of the power customer service work order set), the computer device obtains the processing result of the work order set to be processed based on the processing logic and feeds back the processing result to the external system. Thus, the external system does not need to concern itself with the implementation details of the specific processing logic; it can trigger the entire process and obtain the result simply through command-line parameters. This effectively improves the automation level and operational efficiency of work order processing, facilitates on-demand access to various business systems, enables flexible integration and rapid deployment, meets the work order automation processing needs in different business environments, and possesses good programmability and scalability.
[0076] In one embodiment, the updated content corresponding to each work order is obtained based on the text length of each work order content, including the following steps:
[0077] S1041, Obtain the preset toneless pinyin string corresponding to each candidate word in the preset power industry thesaurus.
[0078] Among them, candidate words refer to professional terms in the field of power customer service, such as power outage, tripping, electricity bill, power restoration, multiple people in one household, name change and transfer, power restoration due to arrears, electricity bill, bank direct debit, charging pile, photovoltaic grid connection, meter reading, meter reading information, electricity price package, account number binding, identity verification, account cancellation and refund, metering abnormality, power supply quality, voltage instability, line aging, safety hazards, meter failure, invoice push, and China Southern Power Grid Online, etc.
[0079] S1042, for each work order content, if the text length of the work order content is less than or equal to the first threshold, determine the target pinyin string that matches each preset pinyin string without tone from the first pinyin string without tone corresponding to the work order content.
[0080] For example, if the first toneless pinyin string corresponding to the work order content is "tiao za le", the target pinyin string is "tiao za" after matching it with various preset toneless pinyin strings.
[0081] The first threshold can be a value between 5 and 15 characters, or it can be set to other ranges. In the embodiments related to this application, the first threshold can be set to 10 characters.
[0082] S1043, determine the edit distance between the target pinyin string and each preset pinyin string without tone.
[0083] Edit distance refers to the minimum number of single-character edit operations required to convert the target pinyin string into a preset pinyin string without tones. Allowed edit operations include: deleting a character and replacing a character.
[0084] In an optional embodiment, determining the edit distance between the target pinyin string and the preset pinyin string without tone marks includes: determining the edit distance between the target pinyin string and the preset pinyin string without tone marks based on the Levenshtein distance algorithm. Alternatively, other methods can be used for determination, and this embodiment does not impose specific limitations.
[0085] S1044, if the minimum edit distance among all edit distances is less than or equal to the preset error correction threshold, update the content corresponding to the target pinyin string in the work order content based on the candidate word corresponding to the minimum edit distance, and obtain the updated content of the work order content.
[0086] S1045, if the minimum edit distance among all edit distances is greater than the preset error correction threshold, obtain the updated content corresponding to the work order content; the updated content is the same as the work order content.
[0087] The preset error correction threshold can be set to any value from 1 to 3. In the embodiments related to this application, the preset error correction threshold can be set to 2.
[0088] In an optional embodiment, if the text length of the work order content is greater than a first threshold, the updated content corresponding to the work order content is obtained; the updated content is the same as the work order content.
[0089] In the above embodiments, for each work order content in the processing group, the work order content is converted into a toneless pinyin string. Given a target pinyin string, the target pinyin string is matched with the preset toneless pinyin strings of candidate words in the power industry thesaurus by edit distance. This automatically identifies and corrects non-standard expressions caused by homophones, spelling errors, or colloquialisms, mapping the short text work order content to standardized professional terminology. When the minimum edit distance is less than or equal to a preset error correction threshold, the work order content is updated based on the candidate words corresponding to the minimum edit distance, achieving standardized error correction and normalization of the short text. When the minimum edit distance is greater than the preset error correction threshold, the original work order content is retained, avoiding erroneous replacement. Therefore, this method significantly improves the standardization and consistency of short text work orders, reduces missed and incorrect judgments caused by homophones and misspellings, and provides an accurate input basis for subsequent similarity calculations based on work order grouping. This effectively improves the accuracy of work order processing, as well as the accuracy and robustness of identifying duplicate work order requests.
[0090] like Figure 2 As shown, a flowchart illustrates a process for obtaining the updated content corresponding to each work order based on the text length of each work order content.
[0091] S201, Read the set of power customer service work orders and the preset toneless pinyin string corresponding to each candidate word in the preset power industry thesaurus; the set of power customer service work orders includes multiple work order contents.
[0092] S202, iterate through each work order and determine the text length of the work order content.
[0093] S203, whether the text length is less than or equal to the first threshold.
[0094] If the text length is less than or equal to the first threshold, then S205 is executed; otherwise, S204 is executed.
[0095] S204, obtain the updated content corresponding to the work order content; the updated content is the same as the work order content.
[0096] S205, from the first toneless pinyin string corresponding to the work order content, determine the target pinyin string that matches each preset toneless pinyin string; determine the edit distance between the target pinyin string and each preset toneless pinyin string.
[0097] S206, determine the minimum edit distance among all edit distances.
[0098] S207, Determine whether the minimum edit distance is less than or equal to the preset error correction threshold.
[0099] If the minimum edit distance is less than or equal to the preset error correction threshold, then S208 is executed; otherwise, S204 is executed.
[0100] S208: Based on the candidate words belonging to the preset toneless pinyin string corresponding to the minimum edit distance, update the content corresponding to the target pinyin string in the work order content to obtain the updated content of the work order.
[0101] S209, group the updated content into at least one pending group; the work order identifiers of the updated content in the pending group are the same.
[0102] In the above embodiments, by determining the short text of each work order content, if the work order content is long text, the original content is retained; if the work order content is short text, the minimum edit distance is used to determine whether to perform matching and error correction. Therefore, this method can be applied to mixed text scenarios, avoiding unnecessary error correction processing for long text work order content. Furthermore, when determining matching and error correction based on the minimum edit distance, replacing the content corresponding to the target pinyin string in the work order content with the candidate word corresponding to the minimum edit distance helps preserve the original context and reduces semantic fragmentation that may result from word-by-word replacement. Moreover, using candidate words from the power industry thesaurus as replacement words for the work order content helps ensure that the replaced work order content conforms to business terminology standards. Furthermore, grouping based on work order identifiers achieves automated and accurate error correction and standardized grouping of power customer service work order sets, significantly improving work order processing efficiency and data quality.
[0103] When the text length of the work order content is less than or equal to the first threshold, the process of determining whether to update the work order content is based on the first toneless pinyin string corresponding to the work order content and the edit distance between each preset toneless pinyin string. Therefore, the process from determining the first toneless pinyin string corresponding to the work order content to obtaining the updated content of the work order content can be called the pinyin normalization process.
[0104] Taking 244 test work orders (including a mixture of short and long text data) as an example, Table 1 shows the results of duplicate detection for these 244 test work orders.
[0105] Table 1
[0106]
[0107] Option A refers to grouping multiple work order contents directly and then processing them accordingly, while Option B refers to grouping the update content of each of the multiple work order contents and then processing them accordingly.
[0108] As shown in Table 1, among the 244 test work orders, the processing time was basically the same as that without the Pinyin normalization method. However, the repetition rate of work orders was increased from 79.7% to 81.3%, which effectively improved the accuracy of the determination of repetitive requests in power customer service work orders.
[0109] Taking the work orders shown in Table 2 as an example, the following methods are used: Figure 2 The method shown can be used to obtain the updated content of the work order, where:
[0110] Table 2
[0111]
[0112] Taking a first threshold of 10 characters as an example, for each work order in Table 2, perform the following steps:
[0113] Step 1: Iterate through each work order and determine if the text length of the work order content is less than or equal to 10 characters. Specifically:
[0114] Work order content 1 (“jumped”): The text length is 3 characters. If the text length is less than or equal to 10 characters, then the work order content 1 will be processed by Pinyin normalization.
[0115] Work order content 2 ("Not yet reviewed"): The text length is 4 characters. If the text length is less than or equal to 10 characters, then the work order content 2 will be processed by Pinyin normalization.
[0116] Work order content 3 ("Electric waste"): The text length is 2 characters. If the text length is less than or equal to 10 characters, then the work order content 3 will be processed by Pinyin normalization.
[0117] Work order content 4 ("I would like to inquire why this month's electricity bill is so much higher than last month's"): The text length is 28 characters. If the text length is greater than 10 characters, then the Pinyin normalization process will not be performed on work order content 4, that is, the original content will be retained, and the updated content of work order content 4 will be the same as work order content 4.
[0118] Work order content 5 ("Stop"): The text length is 2 characters. If the text length is less than or equal to 10 characters, then the work order content 5 will be processed by Pinyin normalization.
[0119] Step 2: Taking a preset error correction threshold of 2 as an example, normalize the work order content.
[0120] The first toneless pinyin string corresponding to work order content 1 ("tiao zha le") is "tiao za le", and the corresponding target pinyin string is "tiao za". Based on the edit distance between the target pinyin string and each preset toneless pinyin string, the candidate word to which the preset toneless pinyin string "tiao zha" corresponding to the minimum edit distance belongs is determined as "trip". Since the minimum edit distance is 1 and less than 2, "tiao zha le" is updated to "tripped".
[0121] The first toneless pinyin string corresponding to work order content 2 ("hai mei fu dian") is "hai mei fu dian", and the corresponding target pinyin string is "fu dian". Based on the edit distance between the target pinyin string and each preset toneless pinyin string, the candidate word to which the preset toneless pinyin string "fu dian" corresponding to the minimum edit distance belongs is determined as "power restoration". Since the minimum edit distance is 0 and less than 2, "hai mei fu dian" is updated to "power not restored yet".
[0122] The first toneless pinyin string corresponding to work order content 3 ("dian fei") is "dian fei", and the corresponding target pinyin string is "dian fei". Based on the edit distance between the target pinyin string and each preset toneless pinyin string, the candidate word to which the preset toneless pinyin string "dian fei" corresponding to the minimum edit distance belongs is determined as "electricity fee". Since the minimum edit distance is 0 and less than 2, "dian fei" is updated to "electricity fee".
[0123] The first toneless pinyin string corresponding to work order content 5 ("ting dian") is "ting dian", and the corresponding target pinyin string is "ting dian". Based on the edit distance between the target pinyin string and each preset toneless pinyin string, the candidate word to which the preset toneless pinyin string "ting dian" corresponding to the minimum edit distance belongs is determined as "power outage". Since the minimum edit distance is 0 and less than 2, "ting dian" is updated to "power outage".
[0124] Thus, based on the above processing, the updated content as shown in Table 3 can be obtained, where:
[0125] Table 3
[0126]
[0127] Further, based on each updated content shown in Table 3, at least one to-be-processed group can be obtained, and work order identifiers of all updated contents in the to-be-processed group are the same. Then, for each to-be-processed group, a first similarity between every two updated contents in the to-be-processed group is determined based on a work order similarity calculation strategy adapted to the text length of the to-be-processed group; and a work order processing result of the power customer service work order set is obtained based on each first similarity corresponding to each to-be-processed group.
[0128] During the test, a total of 45 short text work orders containing the term "chao biao" (exceeding the standard) were selected from certain historical work orders (all text lengths are ≤ 10 characters), such as "customer query for exceeding standard readings", "inquiry about exceeding standard base number", etc. The term "chao biao" in these work orders is a user's pinyin input error, and its intended meaning should be the power industry term "chao biao" (meter reading). Taking the example where the first threshold is set to 10 characters and the preset error correction threshold is set to 2, adopting Figure 2 the method shown can obtain the test results as shown in Table 4, where:
[0129] Table 4
[0130]
[0131] Partial error correction examples are shown in Table 5, where:
[0132] Table 5
[0133]
[0134] The above results show that the Figure 2 method provided in the present application can effectively handle homophonic typos such as "exceeding standard" and "meter reading" in real business scenarios, significantly improving the input quality of short texts and providing a more accurate text basis for subsequent repeated appeal identification. Moreover, the unsuccessful cases can further improve the error correction rate by expanding the lexicon (such as adding the combined word of "meter reading" and "reading value"), which reflects the scalability of the method provided by the present application.
[0135] In actual application scenarios, Figure 2 the method shown can be applied to work order preprocessing in public utility customer service centers for electric power, gas, water supply, etc., and is especially suitable for the demand of pinyin error correction for short texts in mixed text scenarios, which can improve the accuracy of repeated appeal identification for short text work orders in mixed text scenarios. In addition, Figure 2 the method shown can be implemented in Python language and deployed on a Windows server or a Linux server, so that the Windows server or Linux server can perform short text determination on the input work order content item by item by executing Python code, perform pinyin normalization processing on the short text work order content, and keep the long text as it is, realizing automatic short text error correction and standardization processing of power customer service work orders, and effectively improving the identification accuracy of repeated work orders. In addition, the first threshold and the preset error correction threshold can be adjusted according to the actual application scenarios to adapt to different business scenarios.
[0136] In summary, traditional technologies for processing work orders fail to consider the impact of pinyin errors and typos on subsequent work order processes. This application addresses this by introducing pinyin normalization processing, which maps user-input pinyin errors and homophones back to standardized terms in the power industry, thereby improving the accuracy of work order recognition in short text scenarios.
[0137] In one embodiment, determining the first similarity between each updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group includes: determining the second toneless pinyin string corresponding to each updated content in the processing group when the work order similarity calculation strategy adapted to the text length of the processing group is the first similarity calculation strategy; the text length of the processing group is less than or equal to a second threshold; and obtaining the first similarity between each updated content in the processing group based on the similarity between each second toneless pinyin string.
[0138] The first threshold may be the same as or different from the second threshold. For example, the second threshold may be a value between 5 and 15 characters, or it may be set to other ranges. In the embodiments related to this application, the second threshold is set to 10 characters.
[0139] Specifically, when the text length of the group to be processed is less than or equal to the second threshold, the work order similarity calculation strategy that matches the text length of the group to be processed is determined as the first similarity calculation strategy. Here, the text length of the group to be processed refers to the sum of the text lengths of all updated content in the group.
[0140] In an optional embodiment, determining the second toneless pinyin string corresponding to the updated content includes: processing the updated content using the pypinyin library to obtain the second toneless pinyin string corresponding to the updated content.
[0141] In an optional embodiment, determining the similarity between any two second pinyin strings without tone marks includes: determining the edit distance between any two second pinyin strings without tone marks; determining the maximum value among the string lengths of each of the two second pinyin strings without tone marks; determining the ratio between the edit distance and the maximum value; and determining the difference between 1 and the ratio as the similarity between the two second pinyin strings without tone marks.
[0142] In an optional embodiment, determining the similarity between any two second toneless pinyin strings includes: determining the Jaccard similarity between any two second toneless pinyin strings as the similarity between any two second toneless pinyin strings. Specifically, when both second toneless pinyin strings are considered as word sets, the intersection size and union size between the two word sets are determined; the intersection size is divided by the union size to obtain the Jaccard similarity between any two second toneless pinyin strings.
[0143] Among them, any two second toneless pinyin strings can include different second toneless pinyin strings as well as the same second toneless pinyin strings.
[0144] In an optional embodiment, the first similarity between each updated content in the group to be processed is obtained based on the similarity between each second toneless pinyin string, including: determining the similarity between each second toneless pinyin string as the first similarity between each updated content in the group to be processed.
[0145] In the above embodiments, when the text length of the group to be processed is less than or equal to the second threshold, the first similarity between each updated content in the group to be processed is obtained based on the similarity between each second toneless pinyin string in the group to be processed, thereby realizing refined similarity calculation for short text work orders, effectively improving the accuracy of duplicate work order determination and the reliability of grouping and clustering.
[0146] In one embodiment, determining the first similarity between each updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group includes: determining at least two similarity calculation models from multiple preset similarity calculation models; when the work order similarity calculation strategy adapted to the text length of the processing group is a second similarity calculation strategy, determining the first similarity between each updated content in the processing group based on at least two similarity calculation models; the text length of the processing group is greater than a second threshold.
[0147] Specifically, if the text length of the group to be processed is greater than the second threshold, the work order similarity calculation strategy that matches the text length of the group to be processed will be determined as the second similarity calculation strategy.
[0148] Among them, multiple preset similarity calculation models include, but are not limited to, F-IDF model, Jaccard model, DistilBERT model and fastText model.
[0149] In an optional embodiment, determining the first similarity between each updated content in the processing group based on at least two similarity calculation models includes: obtaining a fusion strategy set for at least two similarity calculation models; the fusion strategy includes any one of the sub-strategies of weighted average strategy, maximum value strategy, minimum value strategy, or weighted voting strategy; after cleaning and segmenting each updated content, obtaining the segmented sequence of each updated content based on the segmentation results of each updated content; for each similarity calculation model, calling the similarity calculation model to determine the second similarity between each text sequence; and based on the fusion strategy, analyzing multiple second similarities between each text sequence corresponding to the processing group to obtain the first similarity between each text sequence corresponding to the processing group.
[0150] It is understandable that cleaning the updated content can help purify the text data, reduce noise interference, improve the accuracy and consistency of subsequent word segmentation and similarity calculation, and avoid problems such as key information being buried or mismatched due to format differences or irrelevant characters.
[0151] In an optional embodiment, the method further includes: cleaning the updated content to obtain a first result; and using a word segmentation tool (such as jieba) to segment the first result based on each candidate word in a preset power industry thesaurus to obtain the word segmentation result corresponding to the updated content. Therefore, by introducing a preset power industry thesaurus for word segmentation, the accuracy of professional terminology recognition can be improved, helping to ensure accurate word segmentation and enhance text representation quality, thus providing a more accurate and reliable text sequence foundation for subsequent work order classification, similarity calculation, and duplicate detection.
[0152] In an optional embodiment, based on the word segmentation results corresponding to the updated content, a text sequence corresponding to the updated content is obtained, including: filtering the word segmentation results corresponding to the updated content using a stop word list to obtain the text sequence corresponding to the updated content. Thus, by introducing a stop word list, meaningless common words and noise words can be removed, reducing text dimensionality and improving the accuracy and processing efficiency of work order similarity calculation.
[0153] The stop word list can include words such as "customer" and "caller", and the text sequence must contain at least one word.
[0154] In an optional embodiment, the similarity calculation model is invoked to determine the second similarity between each text sequence, including: sorting each updated content based on the request time corresponding to each updated content in the processing group to obtain the sorted updated content in the processing group; and invoking the similarity calculation model according to the work order order of each updated content in the processing group to determine the second similarity between each text sequence corresponding to the processing group.
[0155] In the embodiments related to this application, the fusion strategy can be a weighted average strategy, or the fusion strategy can be determined according to the actual application scenario. Specifically, based on the fusion strategy, multiple second similarities between the text sequences corresponding to the group to be processed are analyzed to obtain the first similarity between the text sequences corresponding to the group to be processed. This can be implemented in the following exemplary manner:
[0156] In an optional embodiment, based on a fusion strategy, multiple second similarities between text sequences corresponding to the processing group are analyzed to obtain a first similarity between text sequences corresponding to the processing group. This includes: when the fusion strategy is a weighted average strategy, obtaining the model weights of at least two similarity calculation models; for any two text sequences corresponding to the processing group, weighted summing of each second similarity between the two text sequences and their corresponding model weights to obtain an initial similarity; and determining the ratio between the initial similarity and the number of second similarities as the first similarity between the two text sequences. Wherein, any two text sequences include identical text sequences and different text sequences.
[0157] In this embodiment, the sum of the model weights of at least two similarity calculation models is 1. For example, taking at least two similarity calculation models including TF-IDF, Jaccard, DistilBERT, and fastText, the model weights can be set to 0.3 for TF-IDF, 0.1 for Jaccard, 0.4 for DistilBERT, and 0.2 for fastText. The model weights of different similarity calculation models can also be set according to the actual application scenario; this embodiment does not impose limitations.
[0158] In an optional embodiment, based on a fusion strategy, multiple second similarities between text sequences corresponding to the group to be processed are analyzed to obtain a first similarity between text sequences corresponding to the group to be processed. This includes: when the fusion strategy is a maximum value strategy, for any two text sequences corresponding to the group to be processed, the maximum value among the multiple second similarities between any two text sequences is determined as the first similarity between any two text sequences.
[0159] In an optional embodiment, based on a fusion strategy, multiple second similarities between text sequences corresponding to the group to be processed are analyzed to obtain a first similarity between text sequences corresponding to the group to be processed. This includes: when the fusion strategy is a minimum value strategy, for any two text sequences corresponding to the group to be processed, the minimum value among multiple second similarities between any two text sequences is determined as the first similarity between any two text sequences.
[0160] In optional embodiments, the graphical user interface is further configured with checkboxes corresponding to multiple sub-strategies, such as checkboxes corresponding to the weighted average strategy, the maximum value strategy, the minimum value strategy, or the weighted voting strategy. The method further includes: in response to a selection operation on the checkboxes corresponding to a sub-strategy, determining the selected sub-strategy as a fusion strategy set for at least two similarity calculation models.
[0161] In an optional embodiment, the graphical user interface displays checkboxes corresponding to similarity calculation models, such as checkboxes for the TF-IDF model, Jaccard model, DistilBERT model, and fastText model. The method further includes: in response to a selection operation of the checkboxes corresponding to the similarity calculation models, determining at least two selected similarity calculation models as similarity calculation models used to calculate the second similarity between the text sequences corresponding to the group to be processed.
[0162] In an optional embodiment, the graphical user interface further includes a weight input box corresponding to the similarity calculation model, used to input the model weights of the similarity calculation model. The method further includes: for the selected similarity calculation model, determining the model weights of the selected similarity calculation model based on the input content in the input box corresponding to the selected similarity calculation model. Alternatively, the graphical user interface may also include a sliding module, and the method further includes: for the selected similarity calculation model, responding to a sliding event of the sliding module corresponding to the selected similarity calculation model, determining the corresponding value as the model weights of the selected similarity calculation model.
[0163] In the above embodiments, when the text length of the group to be processed is greater than the second threshold, the first similarity between each updated content in the group to be processed is determined based on at least two similarity calculation models. Thus, by integrating the advantages of multiple models, the similarity assessment accuracy between work order content can be improved, and the accuracy of duplicate work order identification can be increased.
[0164] In summary, such as Figure 3 As shown, a flowchart illustrating a work order similarity calculation strategy adapted to the text length of the work order group is provided to determine the first similarity between each updated content in the work order group. The method is illustrated using a computer device as an example, and includes the following steps:
[0165] S302, for each group to be processed, determine the text length of the group to be processed.
[0166] S303, whether the text length is less than or equal to the second threshold.
[0167] If the text length is less than or equal to the second threshold, then S303 and S304 are executed; otherwise, S305 is executed.
[0168] S303, determine the second toneless pinyin string corresponding to each updated content in the pending group.
[0169] S304. Based on the similarity between each second toneless pinyin string, the first similarity between each updated content in the group to be processed is obtained.
[0170] For example, the group to be processed includes three work order contents: Work order content 1 is "Power outage", with a text length of 3; Work order content 2 is "Power not yet restored", with a text length of 4; and Work order content 3 is "Power outage", with a text length of 2. Using the pypinyin library, each work order content is converted into a second toneless pinyin string, namely "tingdian le", "hai mei fu dian", and "ting dian". Further, a Jaccard similarity matrix is calculated based on each second toneless pinyin string. For example, the union of the pinyin of work order content 1 and work order content 3 is {ting,dian,le}, and the intersection is {ting,dian}. The intersection size is 2, and the union size is 3. Therefore, the first similarity between work order content 1 and work order content 3 is 2 / 3 ≈ 0.667. Similarly, the first similarity between work order content 1 and work order content 2, and the first similarity between work order content 2 and work order content 3 can be obtained.
[0171] S305, based on at least two similarity calculation models, determine the first similarity between each updated content in the group to be processed.
[0172] For example, if the group to be processed includes two short texts and one long text, which makes the text length of the group to be processed greater than the second threshold, then at least two of the pre-loaded models such as TF-IDF, Jaccard, DistilBERT, and fastText are called to calculate multiple second similarities between each updated content, and the first similarity between each updated content is determined according to the fusion strategy.
[0173] The specific contents of S301 to S305 can be found in the foregoing description and will not be repeated here.
[0174] use Figure 3 In the illustrated embodiment, a similarity calculation strategy is adaptively selected based on the text length of the groups to be processed. For example, short text groups use pinyin string similarity to avoid noise introduced by complex models; groups containing long texts use multi-model fusion to fully utilize semantic information. This achieves efficient and accurate similarity assessment of power customer service work orders under different text lengths, effectively improving the accuracy of determining duplicate requests. Furthermore, groups of entirely short texts skip time-consuming models such as BERT and directly use lightweight pinyin Jaccard similarity, significantly reducing computational overhead and improving overall processing efficiency.
[0175] In actual testing scenarios, schemes C and D can be set. Scheme C does not consider the text length of the task group and directly uses a multi-model fusion method to determine the first similarity, thereby realizing the determination of duplicate work order requests. Scheme D adaptively selects the similarity calculation strategy based on the text length of the task group, thereby realizing the determination of duplicate work order requests. Taking 50,000 test work orders as an example, the test results are shown in Table 6, where:
[0176] Table 6
[0177]
[0178] As shown in Table 6, the processing time decreased from 26 minutes to 22 minutes (a reduction of approximately 15%), and the duplicate request detection rate increased from 66.1% to 66.8%. Therefore, method D can improve the recognition accuracy while maintaining roughly the same processing time. Thus, method D can significantly optimize the processing efficiency of short text grouping without affecting the accuracy of long text processing, making it particularly suitable for real-world business scenarios where short texts constitute a high proportion.
[0179] In a real-world test scenario, taking the power customer service work order set as a mix of short and long text data, with the work order identifier being a phone number, a total of 59 phone number groups were formed. Of these, 47 groups consisted entirely of short text (all work order texts within the group were ≤15 characters long), and 12 groups contained long text (at least one work order text within the group was >15 characters long). Using the Jaccard similarity algorithm for pinyin, the comparison test results shown in Table 7 can be obtained through the method described in Scheme D above.
[0180] Table 7
[0181]
[0182] As shown in Table 7, in the comparative test of mixed text scenarios, using method D can reduce the average processing time of all short text groups from 0.070 seconds to 0.005 seconds, an efficiency improvement of 14 times, while the processing time for groups containing long texts remains basically unchanged. Therefore, a processing efficiency improvement of up to 14 times is achieved for all short text groups, while the processing time for groups containing long texts remains almost unchanged. This verifies that method D can adaptively select the optimal calculation strategy based on text length in mixed text scenarios, significantly reducing computational overhead while ensuring accuracy.
[0183] In summary, Figure 3The provided method can be applied to the repetitive request identification system for work orders in public utility customer service centers such as those for electricity, gas, and water supply. It can also be extended to other scenarios requiring text similarity calculations that handle mixed text lengths. Furthermore, the method can be implemented using Python and integrated into the work order processing system. Upon system startup, it loads a multi-model fusion processing flow and a similarity determination flow based on pinyin strings. It adaptively selects similarity calculation strategies for groups based on text length, optimizing resource consumption and improving recognition accuracy. The second threshold and the model weights corresponding to each similarity calculation model can be dynamically adjusted to adapt to different business scenarios. In addition, the system provides a graphical configuration interface for business personnel to easily monitor strategy execution.
[0184] In one embodiment, the processing results of the power customer service work order set are obtained based on the first similarity corresponding to each group to be processed, including the following steps:
[0185] S1101, for each group to be processed, based on each first similarity corresponding to the group to be processed, determine the work order duplication judgment threshold that matches the group to be processed.
[0186] In an optional embodiment, the process of determining the duplicate work order determination threshold matching the work order group is based on each first similarity corresponding to the work order group to be processed, including: obtaining the business rules configured for the power customer service work order set; and determining the duplicate work order determination threshold matching the work order group to be processed based on each first similarity corresponding to the work order group to be processed and the business rules.
[0187] For example, the graphical user interface displays a checkbox for whether to enable adaptive threshold. The method further includes: in response to selecting the checkbox for enabling adaptive threshold, determining a duplicate judgment threshold for the work order matching the work order group based on the first similarity scores of each item in the work order group and the business rules. In other words, when the user selects the checkbox for "adaptive threshold," the system automatically calculates and sets an optimal duplicate judgment threshold suitable for the work order group based on the first similarity distribution among the updated content within the current work order group and the configured business rules, instead of using a globally fixed threshold, thereby improving the accuracy and scenario adaptability of duplicate judgment.
[0188] Business rules refer to a series of pre-defined rules for standardizing the classification and processing of updated content. For example, business rules include at least one sub-rule, which includes, but is not limited to: short text penalty rules, time window rules, summary rules (precise summary rules and fuzzy summary rules), and rules for analyzing work orders based solely on work order identifiers (such as phone numbers), among other rules. Short text penalty rules are rules set for processing groups with limited content length and information. Time window rules are time interval restrictions that only compare and classify work orders submitted within a specified time range. Summary rules are rules used to statistically analyze the results of processed updated content. For example, in fuzzy summary, the statistical content includes the request / issue type to which the work order content belongs; in fuzzy summary, the statistical content may include the request / issue type to which the updated content belongs, as well as sub-issue types under that request / issue type. Rules for analyzing work orders based solely on work order identifiers (such as phone numbers) are rules for determining duplicate requests based on the updated content without considering time window rules.
[0189] For example, the types of requests include, but are not limited to: fault reporting, electricity bill inquiries, and service processing. Fault reporting includes, but is not limited to, power outages, unstable voltage, meter malfunctions, line faults, tripping, and burnouts. Electricity bill inquiries include, but are not limited to, questions about electricity bill calculations, bill irregularities, overdue payment notices, payment methods, tiered pricing, and peak / off-peak pricing. Service processing includes, but is not limited to, new installations / capacity increases, and account cancellation refunds.
[0190] In an optional embodiment, the computer device is communicatively connected to the work order processing system. The business rules include at least one sub-rule, and the work order processing system is configured with a graphical user interface (GUI) displaying rule controls corresponding to each sub-rule. The method further includes: responding to configuration operations of the rule controls for the sub-rules in the GUI, combining at least one configured sub-rule to obtain business rules configured for the power customer service work order set.
[0191] For example, the sub-rules include time window rules, where the input box for the time window rule is set to a specific number of days, such as 10 days, with a default number of days of 90. Thus, by setting a specific number of days, work orders within a work order group can be compared only with historical work orders that occurred within that time range before the current moment; work orders outside the window will no longer be considered for duplicate comparison.
[0192] For example, sub-rules include precise summary rules and fuzzy summary rules. The corresponding rule controls can be represented by checkboxes, and either the checkbox for the precise summary rule or the checkbox for the fuzzy summary rule can be selected. Sub-rules include short text penalty rules, and the corresponding rule controls can be represented by checkboxes; sub-rules include rules for analyzing work orders based solely on work order identifiers (such as phone numbers), and the corresponding rule controls can be represented by checkboxes.
[0193] In the above embodiments, by flexibly configuring and combining sub-rules through a graphical interface, the visual and dynamic customization of power customer service work order business rules is realized, which reduces the complexity of rule maintenance and improves the adaptability and scalability of the system.
[0194] In the optional implementation, based on the first similarity scores corresponding to the groups to be processed and the business rules, the threshold for determining duplicate work orders matching the groups to be processed is determined, including the following steps:
[0195] S11. Construct a comprehensive similarity matrix based on the first similarity scores of each group to be processed.
[0196] In an optional embodiment, the method further includes: sorting each updated content in the processing group based on the request time corresponding to each updated content in the processing group, to obtain sorted updated content in the processing group; and determining a first similarity between the text sequences corresponding to any two updated contents in the processing group according to the order of the sorted updated content in the processing group. Wherein, any two updated contents include different updated contents and identical updated contents.
[0197] For example, each element in every n rows of the comprehensive similarity matrix contains: the text sequence corresponding to the nth updated content after sorting in the group to be processed, and the first similarity between it and the text sequences corresponding to each updated content in the group, including itself.
[0198] S12, determine the initial threshold based on the median of the upper triangular elements in the comprehensive similarity matrix and the preset coefficient.
[0199] The median refers to the value in the middle position after all the upper triangular elements in the comprehensive similarity matrix are sorted from smallest to largest.
[0200] In an optional embodiment, determining an initial threshold based on the median of the upper triangular elements in the comprehensive similarity matrix and a preset coefficient includes: determining the product between the median of the upper triangular elements in the comprehensive similarity matrix and the preset coefficient; if the product is within a preset range, determining the product as the initial threshold; if the product is outside the preset range, determining any value within the preset range as the initial threshold.
[0201] The preset coefficient can be 0.7, and the preset range can be [0.15, 0.4]. The preset coefficient and preset range can also be set according to the actual application scenario. This embodiment does not impose any specific limitations.
[0202] In the above embodiments, by dynamically adjusting the judgment threshold based on the similarity distribution within the group, the false judgments and false omissions caused by fixed thresholds can be effectively avoided, thereby improving the accuracy and robustness of duplicate work order judgment.
[0203] S13, if the business rules include short text penalty rules, and the text length of the group to be processed is greater than or equal to the preset length, the initial threshold is determined as the work order duplication judgment threshold that matches the group to be processed.
[0204] S14, If the business rules include short text penalty rules, and the text length of the group to be processed is less than the preset length, then the sum between the initial threshold and the adjustment value is determined as the work order duplication judgment threshold that matches the group to be processed.
[0205] In the relevant embodiments of this application, the preset length can be set to 10 characters, the adjustment value can be set to 0.1, and the specific values of the preset length and the adjustment value can also be set in other ways.
[0206] In the above embodiments, by constructing a comprehensive similarity matrix and determining the initial threshold based on the median of the upper triangular elements and a preset coefficient, and by combining the short text penalty rule to adjust the threshold of the processing group whose text length is less than the preset length, a dynamic adaptive determination process for the work order repetition judgment threshold is realized. Furthermore, a short text penalty mechanism is introduced to adjust the threshold of the processing group with shorter length, thereby significantly improving the accuracy of repetition judgment in short text scenarios while ensuring that the threshold setting is more reasonable.
[0207] In one embodiment, the method further includes: if there is an updated item in the group to be processed, determining the base threshold as the duplicate judgment threshold for the work order matching the work order to be processed. This avoids processing anomalies that occur when the adaptive threshold cannot be calculated due to insufficient work orders in the group, thus improving the stability and reliability of the work order processing flow. The base threshold can be 0.25, or it can be set to other values according to the actual application scenario.
[0208] S1102, if the business rules configured for the power customer service work order set include time window rules, obtain the first historical cluster identifiers of multiple first historical work order contents located before the current time that match the work order identifier and time window rules of the pending group.
[0209] The first historical work order content refers to the work order content that falls within the time range corresponding to the time window rule before the current time (such as the past 24 hours or 90 days). At the same time, the first historical work order content has the same work order identifier as the currently processed pending group (such as the same phone number or the same account number), and each first historical work order content has been pre-classified and marked with its respective issue cluster identifier (i.e., the first historical cluster identifier).
[0210] S1103, when the updated content in the pending group is sorted according to the request time, for each updated content in the pending group after sorting, if the similarity between the updated content and the content of the first historical work order is greater than or equal to the work order duplication determination threshold, then the first historical cluster identifier of the first historical work order content is determined as the problem cluster identifier of the updated content.
[0211] The similarity between the updated content and the first historical work order content refers to the similarity between the text sequence corresponding to the updated content and the text sequence corresponding to the first historical work order content.
[0212] S1104, combine the problem cluster identifier and the work order duplicate identifier of the updated content to obtain the content attributes of the updated content.
[0213] Understandably, by identifying the first historical cluster identifier as the issue cluster identifier for the updated content, it can be concluded that the work order content corresponding to the current updated content belongs to the same issue type as the first historical work order content. Since the current work order content is a duplicate request, the updated content corresponding to the current work order content corresponds to a duplicate work order identifier. Therefore, there is no need to create a new issue cluster or reassign a new request issue type for the current work order content; the classification results of the historical work order content can be directly reused to complete the rapid marking and classification process.
[0214] S1105, based on the content attributes of each updated content in each pending group, obtain the work order processing results of the power customer service work order set.
[0215] In an optional embodiment, the work order processing result of the power customer service work order set is obtained based on the content attributes of each updated content in each to-be-processed group, including: combining the content attributes of each updated content in each to-be-processed group to obtain the work order processing result for the power customer service work order set.
[0216] In an optional embodiment, based on the content attributes of each updated content in each pending group, the work order processing result of the power customer service work order set is obtained, including: for each request work order in each pending group, if the business rules include precise summarization rules, determining the request issue type to which the updated content matches the precise summarization rules, and the sub-issue types under the request issue type; combining the content attributes of the updated content, the request issue type, the sub-issue types, and the text sequence corresponding to the updated content to obtain the processing result of the updated content; combining the processing results of each updated content in each pending group to obtain the work order processing result for the power customer service work order set.
[0217] Among them, precise summary rules are used to reflect the content that the generated work order processing results should include. For example, precise summary rules include major category rules and minor category rules. Major category rules indicate that the work order processing results should include the type of request issue (i.e., primary category, such as "fault repair"); minor category rules indicate that the work order processing results should include the subtypes under the major category (i.e., secondary category, such as fault repair for power outages). The two types of rules work together to ensure that the processing results are hierarchically complete and presented in pairs.
[0218] In an optional embodiment, the precise summarization rules include major category rules and minor category rules. Determining the appeal issue type to which the updated content matches the precise summarization rules belongs, as well as the sub-appeal types under that appeal issue type, includes: analyzing the updated content based on the major and minor category rules in the precise summarization rules to determine the appeal issue type to which the updated content belongs, and the sub-appeal types under that appeal issue type. Thus, through the synergistic constraints of major and minor category rules, it can be ensured that the classification result of each updated content simultaneously includes both a primary appeal issue type and a secondary subtype. These are presented in pairs, with clear hierarchy, providing a well-structured and traceable classification basis for subsequent statistical analysis.
[0219] In an optional embodiment, the method further includes: saving the target result in the form of a DataFrame, the target result including the work order processing results of the power customer service work order set, and the content of each work order in the power customer service work order set.
[0220] In an optional embodiment, the graphical user interface further includes a first browsing component, a first display box corresponding to the first browsing component, a second browsing component, a second display box corresponding to the second browsing component, and a first input box. The method further includes: when the first browsing component is triggered, in response to a selection operation on a work order file, retrieving a power customer service work order set from the work order file based on the content entered in the first input box. The first display box is used to display the name and file type of the work order file, such as displaying "Full Update Content.xlsx"; the first input box is used to specify the specific location of the power customer service work order set within the work order file, such as entering "Summary Table" in the first input box, indicating that the power customer service work order set is located within the "Summary Table" worksheet of the "Full Update Content.xlsx" file.
[0221] In an optional embodiment, the method further includes exporting the work order processing results of the power customer service work order set to an Excel or CSV file. This achieves structured export and data sharing of work order processing results, facilitating subsequent manual review, statistical analysis, and cross-system utilization.
[0222] In an optional embodiment, the method further includes: upon triggering the second browsing component, in response to a selection operation for the exported file, determining the file name exported from the work order processing results of the power customer service work order set, and using a second display box to display the file name exported from the work order processing results, such as the second display box displaying "Update Content_Similar Marking Results.xlsx". Here, "Update Content_Similar Marking Results.xlsx" can be a newly created file or a file containing other data.
[0223] In an optional embodiment, the graphical user interface is further configured with checkboxes corresponding to multi-process parallel processing; the method further includes: in response to the selection operation of the checkboxes corresponding to multi-process parallel processing, calling at least one process corresponding to the set number of parallel processes to be responsible for the processing flow of the corresponding group to be processed, specifically including cleaning and word segmentation of each updated content in the group to be processed, calculating the similarity between text sequences within the group, determining the repetition threshold, and marking the content attributes of each updated content in the group to be processed. For example, setting the number of parallel processes to 2 means that two processes can be started simultaneously to independently process different groups to be processed, thus achieving parallel processing.
[0224] In an optional embodiment, the processing result of the power customer service work order set is obtained based on the first similarity corresponding to each of the groups to be processed, including: invoking a target process to obtain the processing result of the power customer service work order set based on the first similarity corresponding to each of the groups to be processed. The target process can be any one of multiple processes, or it can be another process outside of the multiple processes.
[0225] In the above embodiments, when the user selects the checkbox corresponding to "multi-process parallel processing", the system can call multiple processes to process different groups of pending tasks at the same time according to the set number of parallel processes, which greatly improves the throughput and efficiency of work order processing and shortens the overall processing time.
[0226] In an optional embodiment, the graphical user interface is configured with a checkbox for resuming interrupted downloads. The method further includes: in response to selecting the checkbox for resuming interrupted downloads, if an exception occurs during the processing of the power customer service work order set, recording the current completed processing progress; in response to a reprocessing event for the power customer service work order set, continuing to execute the unfinished processing tasks from the current completed processing progress to obtain the work order processing result for the power customer service work order set. Thus, by automatically recording the processing progress in case of an exception and resuming from the breakpoint upon re-execution, fault-tolerant recovery and efficient continuation of the power customer service work order processing process are achieved, avoiding duplicate calculations of already processed tasks and significantly improving system reliability and resource utilization efficiency.
[0227] In an optional embodiment, the method further includes: displaying the work order processing results of the power customer service work order set through a graphical user interface. This achieves a visual presentation and convenient access to the processing results, improving user experience and decision-making efficiency.
[0228] In an optional embodiment, the method further includes: displaying the processing progress of a set of power customer service work orders through a graphical user interface; and, upon completion of the processing of the set of power customer service work orders, drawing and displaying a pie chart showing the proportion of problems corresponding to the type of complaint or sub-problem types under the complaint type through the graphical user interface. Thus, by displaying real-time processing progress and visualized statistical results, the method achieves visualized monitoring of the processing status of power customer service work orders and self-service analysis of the distribution of complaint issues. This improves the operational analysis efficiency and problem response accuracy of power customer service work orders, assists managers in quickly locating high-frequency complaints, and optimizes resource scheduling and service quality.
[0229] In an optional embodiment, the method further includes displaying the operation log through a graphical user interface. This enables real-time visual monitoring and log traceability of the power customer service work order processing process, improving the system's observability and ease of maintenance.
[0230] In an optional embodiment, the method further includes: drawing and displaying statistical charts through a graphical user interface based on the work order processing results of the power customer service work order set; and exporting the statistical charts as images. The statistical charts are used to characterize the changing trend of the proportion of repetitive requests, the comparison of the proportion of repetitive requests within different time windows, and the distribution of high-frequency repetitive problem types. This achieves the visualization and chart export function of work order processing results, facilitating the generation of analysis reports and cross-platform sharing of results, and improving the flexibility and efficiency of data application. Furthermore, by drawing statistical charts, complex work order processing results can be presented in an intuitive and visual form, reducing the threshold for data understanding and operation, allowing personnel to quickly grasp the distribution and changing trends of repetitive requests without in-depth analysis of raw data, thereby significantly improving the efficiency of daily monitoring and decision analysis.
[0231] In the above embodiments, by dynamically determining the duplicate judgment threshold for each group to be processed, false positives or false negatives caused by fixed thresholds are avoided. This makes the duplicate judgment more consistent with the actual similarity distribution of each group of text, which helps to improve the accuracy of duplicate work order identification and enhances the adaptive capability of work order clustering and issue merging, thereby further optimizing the overall processing quality of power customer service work orders. By combining time window rules, only historical work order cluster identifiers that meet the business timeliness requirements before the current time are obtained, which can improve the timeliness and accuracy of work order duplicate judgment and merging. By sorting the updated content within the group according to the request time and comparing the similarity with the content of historical work orders one by one, if the similarity reaches the threshold, the historical cluster identifier is directly inherited. At the same time, the duplicate work order identifiers are combined to form complete content attributes. Finally, the work order processing results are output based on the content attributes of each group to be processed. This realizes accurate duplicate identification of power customer service work orders, intelligent inheritance of historical clusters, and the integrated application of adaptive thresholds and time window rules, which significantly improves the accuracy of work order clustering and the automation level of processing results.
[0232] In one embodiment, the method further includes: if the similarity between the updated content and any first historical work order content is less than the work order duplication determination threshold, and the similarity between the updated content and other previous updated content in the pending group is less than the work order duplication determination threshold, then based on the updated content, a new problem cluster identifier is constructed; and the new problem cluster identifier and the work order non-duplication identifier of the updated content are combined to obtain the content attributes of the updated content.
[0233] For example, based on the updated content, a new issue cluster identifier is constructed, including: extracting core feature words (such as "electricity meter malfunction" and "overdue payment and no power restoration") from the updated content; and constructing the issue cluster identifier based on the encoding of the core feature words. The newly constructed issue cluster identifier can be stored in association with the updated content and information such as the time of determination of duplicate claims for the updated content, serving as a new benchmark for determining similar claims in the future.
[0234] If the similarity between the updated content and any first historical work order content is less than the work order duplication threshold, and the similarity between the updated content and other updated content in the previous pending group is also less than the work order duplication threshold, it can be concluded that the current updated content does not constitute a duplication relationship with any historical work order content within the time window and other updated content in the current pending group. Therefore, the updated content corresponds to the work order non-duplication identifier, that is, the work order content corresponding to the updated content is the new updated content.
[0235] In the above embodiments, by dynamically constructing new problem cluster identifiers and assigning non-duplicate identifiers to the updated content of work orders that have neither historical similarity nor similar predecessor work orders within the same group, the automatic identification and independent clustering of new problem work orders are realized, avoiding erroneous merging into existing problem clusters, thereby improving the refinement and accuracy of work order processing.
[0236] In one embodiment, the method further includes: if the similarity between the updated content and any first historical work order is less than the work order duplication determination threshold, and the similarity between the updated content and previous updated content in the pending group is greater than or equal to the work order duplication determination threshold, then the issue cluster identifier of the previous updated content is determined as the issue cluster identifier of the current updated content. This achieves automatic inheritance and unified merging of issue cluster identifiers for similar work orders within the same pending group, avoiding the duplication of creating new clusters due to a lack of historical matching, and improving the accuracy of work order duplication determination.
[0237] In one embodiment, the method includes: when the business rules include rules representing the analysis of work orders based solely on work order identifiers, obtaining the second historical cluster identifiers to which each of the multiple second historical work order contents matching the work order identifiers of the pending group belongs; when the updated contents in the pending group are sorted according to the request time, determining a third similarity between the updated contents and each second historical work order content for each sorted updated contents in the pending group; when the third similarity is greater than or equal to the work order duplication determination threshold, determining the second historical cluster identifier to which the second historical work order content belongs as the issue cluster identifier of the updated content; combining the issue cluster identifier and the work order duplication identifier of the updated content to obtain the content attributes of the updated content; or, if the third similarity between the updated content and any second historical work order content is less than the work order duplication determination threshold, and the similarity between the updated content and other previous updated contents in the pending group is less than the work order duplication determination threshold, then constructing a new issue cluster identifier based on the updated content; combining the new issue cluster identifier and the work order non-duplication identifier of the updated content to obtain the content attributes of the updated content. Therefore, by matching all historical work order cluster identifiers based on the work order identifier, and combining intra-group sorting and similarity comparison, the system can achieve duplicate work order identification and problem cluster inheritance or creation without time window restrictions. This improves the adaptability of work order processing rules and the completeness of clustering results, ensuring that accurate merging can be completed based solely on the work order identifier.
[0238] When determining duplicate requests in work orders, traditional technologies often use text clustering methods to classify work orders, such as clustering methods based on term frequency-inverse document frequency (TF-IDF) and KMeans, or topic modeling methods based on Latent Dirichlet Allocation (LDA). However, these methods have the following shortcomings in practical applications: insufficient utilization of semantic information, i.e., TF-IDF and KMeans methods rely solely on word frequency statistics and cannot capture the semantic relationships between words, making it difficult to aggregate synonyms (such as "power outage" and "power cut-off"), thus affecting clustering quality; the number of clusters needs to be preset, i.e., methods such as KMeans require the number of clusters to be specified in advance, but the number of request categories in actual work orders is unknown, and inaccurate preset parameters can lead to mixed or fragmented results; noise points cannot be identified, i.e., each work order is usually forcibly assigned to a certain cluster, making it impossible to identify a small number of abnormal or unique requests (noise), which often have important analytical value; poor hardware adaptability, i.e., some advanced density clustering algorithms, such as Hierarchical Density-Based Spatial Clustering of Applications with Noise, cannot be effectively implemented. While the Noise (HDBSCAN) algorithm can automatically determine the number of clusters and identify noise, it is sensitive to high-dimensional data. When directly applied to word vectors (usually 300-dimensional), it incurs high computational costs and is susceptible to the curse of dimensionality. The results are also poorly interpretable, meaning that the clustering results often only have cluster numbers and lack intuitive topic descriptions, making it difficult for business personnel to understand and use.
[0239] Traditional text processing techniques employ methods such as training word vectors using Word2Vec, obtaining text vectors through TF-IDF weighted summation, and then clustering using K-means or Dbscan. However, these methods have limitations: the Word2Vec model does not consider sub-word information, limiting its ability to represent specialized terms in the power industry (such as "multiple residents per household" and "restoring power after arrears"); while Dbscan can discover clusters of arbitrary shapes, it performs poorly on high-dimensional data and is parameter-sensitive; and it lacks interpretability enhancements for clustering results, making it difficult to apply in business applications. Therefore, there is an urgent need for a power work order clustering method that can fully extract semantic information, automatically determine the number of clusters, identify noise points, and possess good hardware adaptability and interpretability.
[0240] As can be seen from the above, existing clustering methods have insufficient semantic utilization, making it difficult to aggregate synonyms; the number of clusters needs to be preset, resulting in poor adaptability; they cannot identify noise points and lose information about abnormal requests; density clustering calculations are complex under high-dimensional data, requiring high hardware; and the clustering results have poor interpretability, making them difficult for business personnel to use directly.
[0241] Based on this, this application provides the following clustering method. Specifically, in one embodiment, the method further includes: obtaining word segmentation sequences corresponding to each of the multiple first historical work order contents; determining each word vector corresponding to the word segmentation sequence of each first historical work order content for each first historical work order content; performing dimensionality reduction processing on the average vector among the word vectors to obtain the low-dimensional vector corresponding to the first historical work order content; and performing clustering processing on the low-dimensional vectors corresponding to each of the multiple first historical work order contents to obtain the first historical cluster identifier to which each of the multiple first historical work order contents belongs.
[0242] In an optional embodiment, determining the word segmentation sequence corresponding to each of the multiple first historical work order contents includes: for each first historical work order content, after cleaning and segmenting the first historical work order content, obtaining the word segmentation sequence corresponding to the first historical work order content. For example, the first historical work order content "My house has been without power for two days and no one has repaired it" is segmented into "Power outage for two days and no one has repaired it". The specific implementation method of this step can be referred to the foregoing content adaptation description, and will not be repeated here.
[0243] In an optional embodiment, determining the word vectors corresponding to the word segmentation sequence corresponding to the content of the first historical work order includes: inputting each word in the word segmentation sequence corresponding to the content of the first historical work order into a pre-trained word vector model to obtain the word vectors corresponding to the word segmentation sequence.
[0244] The word vector model can be the fastText model or other types of models. In the relevant embodiments of this application, the fastText model can be the pre-trained cc.zh.300.bin, which is trained on Chinese corpora and contains 300-dimensional word vectors.
[0245] Among them, the average vector between word vectors has a high dimension (usually 300 dimensions). If density clustering is performed directly based on the average vector, it will lead to large computational overhead and the effect will be easily affected by the curse of dimensionality. Therefore, by reducing the dimensionality of the average vector, the computational complexity and storage overhead of high-dimensional vectors can be reduced, the curse of dimensionality problem can be alleviated, and the efficiency and accuracy of density clustering can be improved.
[0246] In an optional embodiment, the average vector between each word vector is reduced in dimensionality to obtain a low-dimensional vector corresponding to the content of the first historical work order. This includes: using Principal Component Analysis (PCA) to reduce the dimensionality of the average vector between each word vector to obtain a low-dimensional vector corresponding to the content of the first historical work order.
[0247] The dimension of the low-dimensional vector can be set based on the actual application scenario. For example, based on the target dimension, the PCA method is used to reduce the dimensionality of the average vector among the word vectors to obtain the low-dimensional vector corresponding to the content of the first historical work order. The dimension of the low-dimensional vector is the same as the target dimension. The target dimension can be any value from 10 to 30 dimensions, or it can be dynamically adjusted according to the size of the target dimension dataset and hardware conditions. In the relevant embodiments of this application, the target dimension can be 20 dimensions.
[0248] In an optional embodiment, clustering is performed on the low-dimensional vectors corresponding to each first historical work order content to obtain the first historical cluster identifiers to which each first historical work order content belongs. This includes: using the HDBSCAN method to cluster the low-dimensional vectors corresponding to each first historical work order content to obtain the first historical cluster identifiers to which each first historical work order content belongs.
[0249] The minimum cluster size (min_cluster_size) of the HDBSCAN method can be set according to business needs. For example, min_cluster_size can be 50 or 100. The larger the value, the fewer the clusters and the more noise points.
[0250] The HDBSCAN method automatically determines the number of clusters based on density and marks points that do not belong to any cluster as noise points (labeled -1). Furthermore, the clustering granularity can be controlled by adjusting the parameter min_cluster_size (minimum cluster size). Each historical cluster has a cluster number, which is a positive integer.
[0251] For example, the HDBSCAN method is used to cluster the low-dimensional vectors corresponding to each first historical work order content to obtain the first historical cluster identifiers to which each first historical work order content belongs. This includes: using the HDBSCAN method to cluster the low-dimensional vectors corresponding to each first historical work order content to obtain the historical clusters to which each first historical work order content belongs; and determining the first historical cluster identifiers corresponding to each historical cluster based on the TF-IDF method.
[0252] Specifically, the first historical cluster identifier corresponding to each historical cluster is determined based on the TF-IDF method, including: for each historical cluster, determining the TF-IDF vector of each first historical work order content in the historical cluster; taking the average value of each TF-IDF vector as the cluster center vector; and taking the words with the highest weights corresponding to the TF-IDF vector as the keywords of the historical cluster and determining them as the cluster topic of the historical cluster.
[0253] The number of keywords in a historical cluster can be configured according to the actual application scenario; for example, it can be set to 5 to 10. For instance, taking a keyword count of 10, the segmented texts of all work orders within the historical cluster are merged, the TF-IDF matrix is calculated, the average TF-IDF value of each word is taken as the cluster's center vector, and the top 10 words are sorted and selected as the cluster's keywords. For example, cluster 0 might output keywords such as "power outage, fault, emergency repair, voltage, recovery," while cluster 1 might output keywords such as "electricity fee, abnormality, surge, tiered pricing, meter reading."
[0254] It is understandable that the issue cluster identifier corresponds to the issue cluster topic. Therefore, the semantic category to which the content of the first historical work order belongs can be determined by the first historical cluster identifier. The semantic category is used to describe the core requirements of the work order, such as "power outage and restoration", "abnormal electricity bill", "unstable voltage", etc., which facilitates quick understanding of the work order content and classification.
[0255] In an optional embodiment, the method further includes: using the HDBSCAN method to cluster the low-dimensional vectors corresponding to each first historical work order content to obtain abnormal historical work order content; generating prompt information based on the abnormal historical work order content to prompt manual attention to these isolated requests that are not classified into any regular cluster, so as to improve the comprehensiveness of data mining and business response capabilities.
[0256] Among them, abnormal historical work order content refers to historical work order content that is marked as noise points (labeled as -1) by the HDBSCAN method, that is, those isolated or rare requests that are not connected with other historical work order content in the clustering space and cannot be classified into any historical cluster.
[0257] In an optional embodiment, the method further includes: storing multiple first historical work order contents, the first historical cluster identifier to which each first historical work order contents belongs, and the cluster topic of the historical cluster corresponding to each first historical cluster identifier in the form of a dictionary into a DataFrame, and saving it as an Excel file.
[0258] In summary, such as Figure 4 The diagram illustrates a process for obtaining the identifiers of the first historical clusters to which the contents of multiple first historical work orders belong. Taking the application of this method to a computer device as an example, the process includes the following steps:
[0259] S401, after cleaning and segmenting multiple first historical work order contents, obtain the word segmentation sequence corresponding to each of the multiple first historical work order contents.
[0260] S402, for each first historical work order content, input each word in the word segmentation sequence corresponding to the first historical work order content into the pre-trained FastText model to obtain each word vector corresponding to the word segmentation sequence.
[0261] S403 uses the PCA method to reduce the dimensionality of the average vector between each word vector to obtain the low-dimensional vector corresponding to the content of the first historical work order.
[0262] S404. The HDBSCAN method is used to cluster the low-dimensional vectors corresponding to each first historical work order content to obtain the historical cluster to which each first historical work order content belongs.
[0263] S405, determine the first historical cluster identifier corresponding to each historical cluster based on the TF-IDF method.
[0264] The specific content of S401 to S405 can be found in the aforementioned description and will not be repeated here.
[0265] In an optional embodiment, the method further includes: implementing a method based on the Python language to obtain the first historical cluster identifier to which each of the contents of multiple first historical work orders belongs, and running it in a Windows or Linux environment. The main dependent libraries include: jieba (word segmentation), fastText (word vectors), scikit-learn (PCA, TF-IDF), HDBSCAN (clustering), pandas (data processing), etc.
[0266] In an optional embodiment, the method further includes integrating a method for obtaining the first historical cluster identifiers to which the contents of multiple first historical work orders belong into an intelligent power customer service analysis system. Thus, the system loads the fastText model upon startup and processes work order data according to the steps described above during runtime. Key parameters (such as PCA dimensions, HDBSCAN's min_cluster_size, and the number of keywords) can be adjusted through configuration files to adapt to different datasets and business needs. For data exceeding one million records, it is recommended to use batch processing or optimize vector extraction speed.
[0267] As shown above, by employing the fastText model and fusing the sub-words in the segmented sequence, the semantic similarity of synonyms and power industry terminology can be effectively captured, and the clustering results are more in line with business understanding. Furthermore, the HDBSCAN method does not require pre-setting the number of clusters; it can automatically determine the number of clusters based on data density, exhibiting strong adaptability and avoiding clustering confusion caused by inaccurate preset parameters. Simultaneously, the HDBSCAN method automatically marks noise points, providing the possibility for analyzing abnormal requests and discovering new problems, thus improving the depth of data mining.
[0268] Furthermore, PCA dimensionality reduction preserves most of the variance information in the resulting vectors while significantly reducing the computational overhead of subsequent clustering. It also greatly reduces the sensitivity of HDBSCAN to high-dimensional data, enabling efficient processing of large-scale data even on computers with average configurations. Moreover, by automatically extracting keywords for each cluster, business users can directly understand the cluster's theme, lowering the analytical threshold. Therefore, compared to traditional clustering methods, this application utilizes the fastText model to enhance the representation of domain terminology by leveraging sub-word information.
[0269] Furthermore, the HDBSCAN method is adopted to achieve automatic cluster number identification and noise labeling; a dimensionality reduction step is added to solve the high-dimensional clustering problem; and keyword extraction is added to enhance interpretability. These improvements together constitute a more complete and practical power work order analysis solution. This solution divides the content of the first historical work order into multiple historical clusters, such as "power outage faults," "abnormal electricity bills," and "charging pile services," and automatically identifies a small number of abnormal complaints involving "electromagnetic radiation." Thus, business personnel can quickly understand hot issues through cluster keywords and manually verify noise points, discovering some newly emerging types of requests and providing a basis for service improvement.
[0270] Taking 1294 real work order data (1257 of which are valid after word segmentation preprocessing) as an example, clustering was performed according to the above method. Specifically, a pre-trained FastText Chinese model (cc.zh.300.bin) was used to extract sentence vectors (i.e., the average vector among all word vectors), with a dimension of 300. PCA was used to reduce the dimensionality to 20 dimensions, retaining 84% of the variance information. The HDBSCAN clustering parameter min_cluster_size was set to 50 for automatic clustering. Based on the above settings, the test results shown in Table 8 are obtained:
[0271] Table 8
[0272]
[0273] As shown in Table 9, some historical clusters have keywords and typical work order examples as follows:
[0274] Table 9
[0275]
[0276] Based on the above test results, in the clustering test of 1257 real work orders, the clustering method provided in this application can automatically identify 7 topic clusters and 638 noise points (accounting for 50.8%), successfully discovering abnormal requests such as "electromagnetic radiation". The high proportion of noise points proves that the clustering method can effectively distinguish between mainstream and abnormal requests, providing a powerful tool for business personnel to discover new problems and uncover potential risks. Therefore, by automatically determining the number of clusters (without pre-setting), effectively identifying noise points, and providing interpretable topic descriptions for each cluster through keyword extraction, this clustering method solves the problems of existing technologies that require pre-setting the number of clusters, cannot identify noise, and have uninterpretable results.
[0277] In summary, the clustering method provided in this application integrates the semantic representation capabilities of fastText, the dimensionality reduction processing of PCA, the adaptive clustering and noise identification of HDBSCAN, and the keyword extraction of TF-IDF. It solves the problems of insufficient semantic utilization, the need to pre-determine the number of clusters, the inability to identify noise, and poor interpretability in existing clustering methods. It can efficiently process large-scale work order data on ordinary hardware and is suitable for hotspot mining and anomaly detection in power customer service centers. Furthermore, the above-mentioned clustering method can be widely applied to work order analysis in public utility customer service centers such as electricity, gas, and water supply, and can also be extended to text clustering scenarios in other fields, especially for businesses requiring unsupervised topic discovery and anomaly detection on large-scale text data.
[0278] In summary, such as Figure 5 The diagram illustrates a work order processing method, using an example of its application to computer equipment. The method includes the following steps:
[0279] S501, obtain the set of power customer service work orders and the preset toneless pinyin string corresponding to each candidate word in the preset power industry thesaurus.
[0280] S502, for each work order content, if the text length of the work order content is less than or equal to the first threshold, determine the target pinyin string that matches each preset pinyin string without tone from the first pinyin string without tone corresponding to the work order content.
[0281] S503, determine the edit distance between the target pinyin string and each preset pinyin string without tone.
[0282] S504, based on the relationship between the minimum edit distance among all edit distances and the preset error correction threshold, determines the update content corresponding to the work order content.
[0283] For example, if the minimum edit distance among all edit distances is less than or equal to a preset error correction threshold, the content corresponding to the target pinyin string in the work order content is updated based on the candidate word to which the preset toneless pinyin string belongs, thus obtaining the updated content of the work order content.
[0284] For example, if the minimum edit distance among all edit distances is greater than a preset error correction threshold, the updated content corresponding to the work order content is obtained; the updated content is the same as the work order content.
[0285] S505, group the updated content into at least one pending group; the work order identifiers of the updated content in the pending group are the same.
[0286] S506, when the work order similarity calculation strategy that is adapted to the text length of the group to be processed is the first similarity calculation strategy, determine the second toneless pinyin string corresponding to each updated content in the group to be processed; the text length of the group to be processed is less than or equal to the second threshold.
[0287] S507, based on the similarity between each second toneless pinyin string, the first similarity between each updated content in the group to be processed is obtained.
[0288] S508, when the work order similarity calculation strategy adapted to the text length of the group to be processed is the second similarity calculation strategy, the first similarity between each updated content in the group to be processed is determined based on at least two similarity calculation models; the text length of the group to be processed is greater than the second threshold.
[0289] S509, for each group to be processed, based on each first similarity corresponding to the group to be processed, determine the work order duplication determination threshold that matches the group to be processed.
[0290] S510, where the business rules configured for the power customer service work order set include time window rules, obtain the first historical cluster identifiers of multiple first historical work order contents located before the current time that match the work order identifier and time window rules of the pending group.
[0291] S511, when the updated content in the pending group is sorted according to the time of the request, for each updated content in the pending group after sorting, if the similarity between the updated content and the content of the first historical work order is greater than or equal to the work order duplication determination threshold, then the first historical cluster identifier of the first historical work order content is determined as the problem cluster identifier of the updated content.
[0292] S512, combine the problem cluster identifier and the work order duplicate identifier of the updated content to obtain the content attributes of the updated content.
[0293] S513, based on the content attributes of each updated content in each pending group, obtain the work order processing results of the power customer service work order set.
[0294] The specific contents of S501 to S513 can be found in the foregoing description and will not be repeated here.
[0295] In the above embodiments, through an end-to-end processing flow from short text pinyin correction of work orders, length adaptive similarity calculation, dynamic threshold determination to temporal historical cluster inheritance, automated cleaning, accurate deduplication and intelligent merging of power customer service work orders are realized, which significantly improves the accuracy and efficiency of work order processing.
[0296] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.
[0297] Based on the same inventive concept, this application also provides a work order processing apparatus for implementing the work order processing method described above. The solution provided by this apparatus is similar to the solution described in the above method; therefore, the specific limitations in one or more work order processing apparatus embodiments provided below can be found in the limitations of the work order processing method described above, and will not be repeated here.
[0298] In one exemplary embodiment, such as Figure 6 As shown, a work order processing device is provided, including: an acquisition module 601, an analysis module 602, a division module 603, a first processing module 604, and a second processing module 605, wherein:
[0299] The system comprises: an acquisition module 601 for acquiring a set of power customer service work orders, the set including multiple work order contents; an analysis module 602 for obtaining updated content corresponding to each work order content based on its text length; a division module 603 for grouping the updated content into at least one processing group; the work order identifiers of the updated content in each processing group being identical; a first processing module 604 for determining a first similarity between the updated content in each processing group based on a work order similarity calculation strategy adapted to the text length of the processing group; and a second processing module 605 for obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each processing group.
[0300] In one embodiment, the analysis module 602 is further configured to: obtain a preset toneless pinyin string corresponding to each candidate word in a preset power industry thesaurus; for each work order content, if the text length of the work order content is less than or equal to a first threshold, determine a target pinyin string matching each preset toneless pinyin string from the first toneless pinyin string corresponding to the work order content; determine the edit distance between the target pinyin string and each preset toneless pinyin string; if the minimum edit distance among the edit distances is less than or equal to a preset error correction threshold, update the content corresponding to the target pinyin string in the work order content based on the candidate word to which the preset toneless pinyin string corresponding to the minimum edit distance belongs, thereby obtaining the updated content of the work order content; if the minimum edit distance among the edit distances is greater than the preset error correction threshold, obtain the updated content corresponding to the work order content; the updated content is the same as the work order content.
[0301] In one embodiment, the first processing module 604 is further configured to: determine the second toneless pinyin string corresponding to each of the updated contents in the processing group when the work order similarity calculation strategy adapted to the text length of the processing group is a first similarity calculation strategy; the text length of the processing group is less than or equal to a second threshold; and obtain the first similarity between each of the updated contents in the processing group based on the similarity between each of the second toneless pinyin strings.
[0302] In one embodiment, the first processing module 604 is further configured to: determine at least two similarity calculation models from a plurality of preset similarity calculation models; and, when the work order similarity calculation strategy adapted to the text length of the group to be processed is the second similarity calculation strategy, determine a first similarity between each of the updated contents in the group to be processed based on the at least two similarity calculation models; wherein the text length of the group to be processed is greater than a second threshold.
[0303] In one embodiment, the second processing module 605 is further configured to: for each of the pending groups, determine a work order duplication threshold matching the pending group based on the first similarity values corresponding to each of the pending groups; when the business rules configured for the power customer service work order set include time window rules, obtain the first historical cluster identifiers of multiple first historical work order contents located before the current time that match the work order identifier of the pending group and the time window rules; when each of the updated contents in the pending group is sorted according to the request time, for each of the sorted updated contents in the pending group, if the similarity between the updated content and the first historical work order content is greater than or equal to the work order duplication threshold, determine the first historical cluster identifier of the first historical work order content as the issue cluster identifier of the updated content; combine the issue cluster identifier and the work order duplication identifier of the updated content to obtain the content attribute of the updated content; and obtain the work order processing result of the power customer service work order set based on the content attributes of each of the updated contents in each of the pending groups.
[0304] In one embodiment, the second processing module 605 is further configured to: obtain the word segmentation sequence corresponding to each of the plurality of first historical work order contents; for each first historical work order content, determine each word vector corresponding to the word segmentation sequence corresponding to the first historical work order content; perform dimensionality reduction processing on the average vector among the word vectors to obtain the low-dimensional vector corresponding to the first historical work order content; and perform clustering processing on the low-dimensional vector corresponding to each of the first historical work order contents to obtain the first historical cluster identifier to which each of the plurality of first historical work order contents belongs.
[0305] Each module in the aforementioned work order processing device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0306] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 7As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores data during work order processing. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When the computer program is executed by the processor, it implements a work order processing method.
[0307] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 8 As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a work order processing method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.
[0308] Those skilled in the art will understand that Figure 7 or Figure 8The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0309] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.
[0310] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.
[0311] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.
[0312] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0313] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0314] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0315] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A work order processing method, characterized in that, The method includes: Obtain a set of electricity customer service work orders; the set of electricity customer service work orders includes multiple work order contents; Based on the text length of each of the multiple work order contents, the update content corresponding to each of the work order contents is obtained; Each of the updated content items is grouped to obtain at least one pending group; the work order identifiers of each of the updated content items in the pending group are the same; For each of the pending groups, a first similarity between each of the updated contents in the pending group is determined based on a work order similarity calculation strategy adapted to the text length of the pending group. Based on the first similarity corresponding to each of the groups to be processed, the processing result of the power customer service work order set is obtained.
2. The method according to claim 1, characterized in that, The step of obtaining the updated content corresponding to each of the multiple work order contents based on their respective text lengths includes: Obtain the preset toneless pinyin string corresponding to each candidate word in the preset power industry thesaurus; For each work order content, if the text length of the work order content is less than or equal to a first threshold, a target pinyin string that matches each of the preset pinyin strings is determined from the first pinyin string without tone corresponding to the work order content. Determine the edit distance between the target pinyin string and each of the preset pinyin strings without tone marks; If the minimum edit distance among the various edit distances is less than or equal to a preset error correction threshold, the content corresponding to the target pinyin string in the work order content is updated based on the candidate word to which the preset toneless pinyin string belongs, and the updated content of the work order content is obtained. If the minimum edit distance among the various edit distances is greater than the preset error correction threshold, the updated content corresponding to the work order content is obtained; the updated content is the same as the work order content.
3. The method according to claim 1, characterized in that, The work order similarity calculation strategy, adapted to the text length of the group to be processed, determines the first similarity between each updated content in the group to be processed, including: When the work order similarity calculation strategy that is adapted to the text length of the group to be processed is the first similarity calculation strategy, the second toneless pinyin string corresponding to each of the updated contents in the group to be processed is determined; the text length of the group to be processed is less than or equal to the second threshold. Based on the similarity between each of the second toneless pinyin strings, the first similarity between each of the updated contents in the group to be processed is obtained.
4. The method according to claim 1, characterized in that, The work order similarity calculation strategy, adapted to the text length of the group to be processed, determines the first similarity between each updated content in the group to be processed, including: From multiple preset similarity calculation models, at least two similarity calculation models are determined; When the work order similarity calculation strategy adapted to the text length of the group to be processed is the second similarity calculation strategy, the first similarity between each of the updated contents in the group to be processed is determined based on the at least two similarity calculation models; the text length of the group to be processed is greater than the second threshold.
5. The method according to any one of claims 1 to 4, characterized in that, The process of obtaining the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the respective groups to be processed includes: For each of the groups to be processed, a work order duplication threshold matching the group to be processed is determined based on each of the first similarities corresponding to the group to be processed. When the business rules configured for the power customer service work order set include time window rules, obtain the first historical cluster identifiers of each of the multiple first historical work order contents that are located before the current time and match the work order identifier of the pending group and the time window rules. When the updated content in the pending group is sorted according to the request time, if the similarity between the updated content and the first historical work order content is greater than or equal to the work order duplication determination threshold, the first historical cluster identifier of the first historical work order content is determined as the problem cluster identifier of the updated content. By combining the problem cluster identifier and the work order duplicate identifier of the updated content, the content attributes of the updated content are obtained; Based on the content attributes of each updated content in each of the pending groups, the work order processing result of the power customer service work order set is obtained.
6. The method according to claim 5, characterized in that, The method further includes: Obtain the word segmentation sequence corresponding to the content of each of the multiple first historical work orders; For each piece of the first historical work order content, determine the word vectors corresponding to the word segmentation sequence corresponding to the first historical work order content; The average vector among the word vectors is reduced in dimensionality to obtain the low-dimensional vector corresponding to the content of the first historical work order. Clustering is performed on the low-dimensional vectors corresponding to each of the first historical work order contents to obtain the first historical cluster identifiers to which each of the multiple first historical work order contents belongs.
7. A work order processing device, characterized in that, The device includes: The acquisition module is used to acquire a set of power customer service work orders; the set of power customer service work orders includes multiple work order contents. The analysis module is used to obtain the update content corresponding to each of the multiple work order contents based on their respective text lengths. A segmentation module is used to group the various updated contents to obtain at least one pending group; the work order identifiers of the various updated contents in the pending group are the same; The first processing module is used to determine the first similarity between each updated content in the processing group based on a work order similarity calculation strategy adapted to the text length of the processing group. The second processing module is used to obtain the work order processing result of the power customer service work order set based on the first similarity corresponding to each of the respective groups to be processed.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.