Short text data processing method and device for hospital logistics operation and maintenance
By constructing a custom word segmentation lexicon and using fuzzy matching technology, the problem of low accuracy in short text data processing in hospital logistics operations has been solved, enabling precise extraction and semantic understanding of key information and supporting the intelligent upgrade of logistics services.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NANJING TIANSU AUTOMATION CONTROL SYST CO LTD
- Filing Date
- 2019-12-31
- Publication Date
- 2026-07-31
AI Technical Summary
Existing short text data processing methods suffer from low accuracy, inability to classify data, and inability to aggregate data to higher levels in hospital logistics operations and maintenance. Traditional methods cannot meet the natural language processing needs of hospital logistics operations and maintenance.
By building a custom word segmentation lexicon, performing full-mode word segmentation and cleaning, and using fuzzy matching and word frequency statistics, the category and position of keywords are determined, and auxiliary information is merged for word segmentation to improve accuracy.
It achieves precise segmentation and semantic understanding of short texts, improves the accuracy of extracting key information, and supports the intelligent and IT-based upgrade of logistics operations.
Smart Images

Figure CN111161861B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of signal processing technology, and in particular to a method, apparatus, computer equipment, and storage medium for processing short text data for hospital logistics and maintenance. Background Technology
[0002] Reporting repairs is an extremely frequent and crucial daily task within large and super-large functional building complexes, as various automated machines, equipment, and systems experience unpredictable malfunctions. To ensure normal operation, a dedicated logistics team is typically assigned to perform various maintenance and repair tasks across the entire system. This process involves various stages, such as the discovery, reporting, recording, and assessment of maintenance points. Traditionally, key information at each stage is manually recorded, a process inherently cumbersome. While IT advancements have largely replaced software in this area, current changes primarily focus on digitizing highly mechanical tasks. Tasks requiring even slight subjective judgment still require human intervention. Even cutting-edge artificial intelligence technology falls far short of solving these problems, particularly in natural language processing, where inherent challenges have hindered technological development. Hospital logistics operations involve significant amounts of natural language and text processing; if this technology matures sufficiently, it will bring substantial efficiency improvements and cost reductions to this field.
[0003] Based on actual conditions, key textual information in the hospital logistics and maintenance field has its inherent characteristics, such as a limited number of objects, relatively simple sentence structure and semantics, and limited sentence length. These characteristics provide the possibility for automatic text processing in specific scenarios. For example, the sentence "The hose under the sink in the women's changing room on the right side of the First Endoscopy Center in the East Campus is broken" needs to be segmented and extracted according to different dimensions such as "Campus: [], Area: [], Department: [], Object: [], Fault: []". This is an extremely simple task for humans, but it is an extremely complex process for computers to complete the same task. Existing related processing methods usually fall into the following categories:
[0004] Regular expression matching: It uses predefined specific characters and their combinations to generate a "fixed" pattern, and recursively applies the pattern to the text object to be processed. When the text and its sub-fragments satisfy the pattern, it means that the match is successful.
[0005] Keyword extraction based on statistical methods involves first segmenting the original text into different fragments, then calculating the frequency or weight of each word using various methods. The word with the highest score is then identified as the keyword. Examples include the TextRank algorithm, RAKE algorithm, and TF-IWF algorithm.
[0006] Keyword extraction based on machine learning can be categorized by learning method into supervised keyword extraction, semi-supervised keyword extraction, and unsupervised keyword extraction. From a mathematical perspective, it can be further divided into keyword extraction methods based on statistical features, keyword extraction methods based on word graph models, and keyword extraction methods based on topic models.
[0007] Keyword extraction is one of the core tasks in text processing, especially short text data processing, and is also an important branch of natural language processing. However, existing keyword extraction technologies struggle to achieve accurate keyword segmentation and extraction from short texts, mainly due to the following key problems:
[0008] Regularization matching methods: First, regularization methods must satisfy a fixed pattern, which is only suitable for applications requiring precise matching. They are too simplistic for extracting keywords from short texts with complex pattern variations and cannot meet practical needs. Second, this method requires accurate "signals" during matching, which further limits its application.
[0009] Statistical methods are effective for extracting keywords from long texts, but have little effect on short texts. This is because keywords tend to appear more frequently than other words in long texts, while it is difficult for short texts or individual sentences to contain repeated keywords, thus losing the factual basis for using statistical methods.
[0010] Machine learning-based methods have several drawbacks. First, they require large corpora for training, especially deep learning, which uses neural networks as its core, and has extremely demanding requirements for training data. Second, the core algorithms of machine learning methods are usually based on some kind of text model or language expression model, such as a grammatical network graph, or by calculating certain parameters, such as a clustering coefficient. These features are not obvious in very short texts. Third, machine learning-based methods are not accurate enough in keyword classification and cannot meet practical needs.
[0011] The aforementioned methods share two common problems: first, they cannot categorize the extracted keywords, for example, "operating room" belongs to "room" but not "floor"; second, they cannot aggregate the extracted keywords to a higher level to form meaningful phrases, such as "The hose under the sink in the women's changing room on the right side of the East Campus First Endoscopy Center is going to fall off." Conventional word segmentation or partitioning results would typically be "East Campus\First\Endoscopy Center\Right Side\Women's Changing Room\Sink\Under\Of\Hose\Going to Fall Off," but in practice, it might be more desirable to get "East Campus\First Endoscopy Center Right Side\Women's Changing Room Sink\Under\Of\Hose\Going to Fall Off." It is evident that traditional short text data processing solutions often suffer from low accuracy. Summary of the Invention
[0012] To address the above problems, this invention proposes a short text data processing method, apparatus, computer equipment, and storage medium for hospital logistics operations and maintenance.
[0013] To achieve the objectives of this invention, a short text data processing method for hospital logistics operations and maintenance is provided, comprising the following steps:
[0014] S10, determine a classification lexicon based on the corpus; the classification lexicon is used to describe the word category of each word included in the corpus;
[0015] S20, the classified vocabulary is reorganized according to the preset word segmentation method to obtain a preliminary word segmentation vocabulary. The corpus is segmented according to the preliminary word segmentation vocabulary. The word frequency of each keyword after segmentation is statistically analyzed. The statistical results are added to the preliminary word segmentation vocabulary to obtain a custom word segmentation vocabulary.
[0016] S30, the custom word segmentation dictionary is used to perform full-mode word segmentation on the short text to be processed. The word segmentation results of the full-mode word segmentation are cleaned to obtain auxiliary information word segmentation and multiple valid items of the short text to be processed. Fuzzy matching is used to match each valid item in the classification dictionary to obtain the initial matching results of each valid item. The matching result with the highest word frequency in the initial matching results of each valid item is selected as the final matching result of each valid item.
[0017] S40, determine the effective text information of the short text to be processed based on auxiliary information word segmentation and final matching results.
[0018] In one embodiment, determining the valid text information of the short text to be processed based on auxiliary information word segmentation and the final matching result includes:
[0019] Determine the final matching results' order and position, and then determine the effective word sequence based on the order.
[0020] Determine the position of the auxiliary information segmentation within the effective word sequence;
[0021] The auxiliary information segmentation and the effective word sequence are merged based on their positions in the effective word sequence.
[0022] In one embodiment, before determining the classification lexicon based on the corpus, the method further includes:
[0023] Collect statements that occur within a specified time period for the described object to obtain statement sources, and construct a corpus based on the statement sources.
[0024] As one example, the described object includes a hospital.
[0025] In one embodiment, after reorganizing the classified lexicon according to a preset word segmentation method to obtain a preliminary word segmentation lexicon, performing word segmentation on the corpus based on the preliminary word segmentation lexicon, performing word frequency statistics on each keyword after word segmentation, and adding the statistical results to the preliminary word segmentation lexicon to obtain a custom word segmentation lexicon, the method further includes:
[0026] Obtain a public stop word library, and construct a custom stop word library based on the public stop word library and the classification word library; the custom stop word library is used to clean the word segmentation results of full-mode word segmentation.
[0027] As an example, the cleaning of the word segmentation results for the full-mode word segmentation includes:
[0028] The custom stop word library is used to identify stop words in the full-mode word segmentation results. After removing the identified stop words, duplicate words in the full-mode word segmentation results are removed to obtain multiple valid items. The identified stop words are then determined as auxiliary information for word segmentation.
[0029] A short text data processing device for hospital logistics operations and maintenance includes:
[0030] The first determining module is used to determine a classification lexicon based on the corpus; the classification lexicon is used to describe the word category of each word included in the corpus;
[0031] The reorganization module is used to reorganize the classified word library according to a preset word segmentation method to obtain a preliminary word segmentation word library, perform word segmentation processing on the corpus based on the preliminary word segmentation word library, perform word frequency statistics on each keyword after word segmentation, and add the statistical results to the preliminary word segmentation word library to obtain a custom word segmentation word library;
[0032] The word segmentation module is used to perform full-mode word segmentation on the short text to be processed using the custom word segmentation dictionary, clean the word segmentation results of the full-mode word segmentation, obtain auxiliary information word segmentation and multiple valid items of the short text to be processed, match each valid item in the classification dictionary using fuzzy matching, obtain the initial matching results of each valid item, and select the matching result with the highest word frequency from the initial matching results of each valid item as the final matching result of each valid item.
[0033] The second determining module is used to determine the valid text information of the short text to be processed based on auxiliary information word segmentation and the final matching result.
[0034] In one embodiment, the second determining module is used to:
[0035] Determine the final matching results and their order; then determine the effective word sequence based on the order.
[0036] Determine the position of the auxiliary information segmentation within the effective word sequence;
[0037] The auxiliary information segmentation and the effective word sequence are merged based on their positions in the effective word sequence.
[0038] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the short text data processing method for hospital logistics operations and maintenance according to any of the above embodiments.
[0039] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the short text data processing method for hospital logistics operations and maintenance according to any of the above embodiments.
[0040] The aforementioned method, apparatus, computer equipment, and storage medium for short text data processing in hospital logistics operations and maintenance involve: determining a classification lexicon based on a corpus; reorganizing the classification lexicon according to a preset word segmentation method to obtain a preliminary word segmentation lexicon; performing word segmentation on the corpus based on the preliminary word segmentation lexicon; performing word frequency statistics on each keyword after word segmentation; adding the statistical results to the preliminary word segmentation lexicon to obtain a custom word segmentation lexicon; using the custom word segmentation lexicon to perform full-mode word segmentation on the short text to be processed; cleaning the word segmentation results to obtain auxiliary information word segments and multiple valid items for the short text to be processed; using fuzzy matching to match each valid item in the classification lexicon to obtain initial matching results for each valid item; selecting the matching result with the highest word frequency from the initial matching results for each valid item as the final matching result for each valid item; and thus accurately segmenting the short text to be processed semantically to obtain auxiliary information word segments and final matching results, thereby determining the valid text information of the short text to be processed and improving the accuracy of the determined valid text information. This method will significantly improve the accuracy of key information extraction, keyword extraction, classification and statistical analysis of short texts in hospital logistics. It provides a methodological foundation for the intelligent and IT-based upgrading of some logistics operations. Attached Figure Description
[0041] Figure 1 This is a flowchart of a short text data processing method for hospital logistics operations and maintenance, as exemplified by one of the following embodiments;
[0042] Figure 2 This is a schematic diagram of a custom word segmentation dictionary in one embodiment;
[0043] Figure 3 This is a schematic diagram illustrating the process of obtaining matching results in one embodiment;
[0044] Figure 4 This is a schematic diagram showing the arrangement of main and auxiliary information in one embodiment;
[0045] Figure 5 This is a schematic diagram illustrating auxiliary information word segmentation and merging in one embodiment;
[0046] Figure 6 This is a schematic diagram illustrating auxiliary information word segmentation and merging in one embodiment;
[0047] Figure 7 This is a schematic diagram illustrating auxiliary information word segmentation and merging in one embodiment;
[0048] Figure 8 This is a schematic diagram of the structure of a short text data processing device for hospital logistics operations and maintenance, according to one embodiment.
[0049] Figure 9 This is a schematic diagram of a computer device according to one embodiment. Detailed Implementation
[0050] 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.
[0051] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0052] The short text data processing method for hospital logistics operations and maintenance provided in this application can be applied to short text data processing terminals in hospital logistics operations and maintenance. The aforementioned short text data processing terminal can determine a classification lexicon based on a corpus, reorganize the classification lexicon according to a preset word segmentation method to obtain a preliminary word segmentation lexicon, perform word segmentation processing on the corpus based on the preliminary word segmentation lexicon, perform word frequency statistics on each keyword after word segmentation, and add the statistical results to the preliminary word segmentation lexicon to obtain a custom word segmentation lexicon. The custom word segmentation lexicon is used to perform full-mode word segmentation on the short text to be processed. The word segmentation results of the full-mode word segmentation are cleaned to obtain auxiliary information word segmentation and multiple valid items for the short text to be processed. Fuzzy matching is used to match each valid item in the classification lexicon to obtain the initial matching results for each valid item. The matching result with the highest word frequency among the initial matching results for each valid item is selected as the final matching result for each valid item. The valid text information of the short text to be processed is determined based on the auxiliary information word segmentation and the final matching results, thereby improving the accuracy of the determined valid text information of the short text to be processed. The short text data processing terminal can be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices.
[0053] In one embodiment, such as Figure 1 As shown, a short text data processing method for hospital logistics operations and maintenance is provided. Taking the application of this method to a short text data processing terminal as an example, the method includes the following steps:
[0054] S10, determine a classification lexicon based on the corpus; the classification lexicon is used to describe the word category of each word included in the corpus.
[0055] Specifically, the classification thesaurus can be customized based on the descriptive objects of the corpus. The ultimate purpose of the classification thesaurus is twofold: first, to determine the categories of extracted keywords; and second, to resolve potential word order issues in the original short text. For example, the phrase "Two lights were broken on the second floor of the East Campus" should conventionally be "Two lights were broken on the second floor of the East Campus." However, after word segmentation and reorganization, the result is "Two lights were broken\Second floor\East Campus," clearly belonging to different dimensions. By defining categories for each dimension, it's possible to adjust the sentence structure to a more conventional pattern. Building a classification thesaurus is essentially a tagging process. There are several methods to obtain a classification thesaurus; it can be obtained manually from the corpus or by downloading relevant sub-type keyword libraries to assemble the classification thesaurus. For example, key information in a hospital's logistics and maintenance work order can be categorized into: area, floor, department, object, phenomenon, location, etc. (word categories). In one example, part of the above classification thesaurus can be seen in Table 1.
[0056] Table 1. Schematic diagram of some contents of the categorized thesaurus
[0057]
[0058] S20, the classified word library is reorganized according to the preset word segmentation method to obtain a preliminary word segmentation word library. The corpus is segmented according to the preliminary word segmentation word library. The word frequency of each keyword after segmentation is statistically analyzed. The statistical results are added to the preliminary word segmentation word library to obtain a custom word segmentation word library.
[0059] The preset word segmentation method can be set according to the description object of the corpus.
[0060] In one example, reference Figure 2 As shown in Table 1, the above steps are illustrated using the categorized thesaurus. Figure 2 The final word segmentation library shown is a custom word segmentation library:
[0061] Due to the specific requirements of the domain in which the described object exists, conventional word segmentation methods cannot adapt to specialized fields, thus necessitating the creation of a proprietary word segmentation dictionary. The formation of this dictionary involves two steps:
[0062] (1) Reorganize the classification lexicon according to the word segmentation method requirements. At this time, the lexicon does not contain word frequency, but it has initially acquired the function of custom word segmentation, only the word segmentation accuracy is slightly lower.
[0063] (2) Use the preliminary word segmentation lexicon obtained in step (1) to segment the entire corpus, perform word frequency statistics on each keyword after segmentation, and add the final statistical results to the word segmentation lexicon obtained in step (1) to obtain a complete custom word segmentation lexicon.
[0064] S30, the custom word segmentation dictionary is used to perform full-mode word segmentation on the short text to be processed. The word segmentation results of the full-mode word segmentation are cleaned to obtain auxiliary information word segmentation and multiple valid items of the short text to be processed. Fuzzy matching is used to match each valid item in the classification dictionary to obtain the initial matching results of each valid item. The matching result with the highest word frequency in the initial matching results of each valid item is selected as the final matching result of each valid item.
[0065] The above full-mode word segmentation process can utilize open-source word segmentation tools (such as jieba, SnowNLP, THULAC, NLPIR, etc.). The auxiliary information segmentation can include words such as location, ordinal numbers, digits, and letters.
[0066] Specifically, the above steps involve performing full-mode word segmentation on the original short text to be processed. Open-source word segmentation tools (such as jieba, SnowNLP, THULAC, NLPIR, etc.) can be used for segmentation. It is important to note that the word segmentation dictionary must be the custom word segmentation dictionary obtained from S20. Stop words and duplicate words are removed from the segmented results to filter out meaningless segments and further refine the selection of valid entries. The cleaned word segments are then matched against the classification dictionary using fuzzy matching, and the matching results are ranked. The highest scorer is taken as the final matching result.
[0067] In one example, the process of obtaining the matching result (such as the final matching result) can be referred to Figure 3 As shown.
[0068] Furthermore, in the field of hospital logistics operations and maintenance, the main content of a work order can generally be described using the pattern "[Area, Building, Floor, Department, Room, Object, Phenomenon]". Here, "Area, Building, Floor, Department, Room" describes the location information, "Object" describes the specific thing to be processed, and "Phenomenon" describes the specific situation of the "Object," which are called the main information. These main pieces of information can be represented by "1, 2, 3, 4, 5, 6, 7" respectively. A complete work order should be in the pattern "[1,2,3,4,5,6,7]", or at least "[6,7]", meaning it must contain at least an object and a phenomenon; otherwise, the work order is meaningless. "Location, Ordinal Number, Number, Letter" can be represented by "a, b, c, d" respectively, and are called auxiliary information. Optionally, a diagram illustrating the arrangement of main information (such as valid items) and auxiliary information can be referenced. Figure 4 As shown.
[0069] S40, determine the effective text information of the short text to be processed based on auxiliary information word segmentation and final matching results.
[0070] The above steps can help merge the remaining final matching results using the features of word segmentation to determine the effective text information of the short text to be processed, thus ensuring the accuracy of the obtained effective text information.
[0071] The aforementioned short text data processing method for hospital logistics operations and maintenance involves determining a classification lexicon based on a corpus, reorganizing the classification lexicon according to a preset word segmentation method to obtain a preliminary word segmentation lexicon, segmenting the corpus based on the preliminary word segmentation lexicon, performing word frequency statistics on each keyword after word segmentation, and adding the statistical results to the preliminary word segmentation lexicon to obtain a custom word segmentation lexicon. The custom word segmentation lexicon is then used to perform full-mode word segmentation on the short text to be processed. The segmentation results of the full-mode word segmentation are cleaned to obtain auxiliary information word segments and multiple valid items for the short text to be processed. Fuzzy matching is used to match each valid item in the classification lexicon to obtain initial matching results for each valid item. The matching result with the highest word frequency among the initial matching results for each valid item is selected as the final matching result for each valid item. This allows for precise semantic segmentation of the short text to be processed, obtaining auxiliary information word segments and final matching results, thereby determining the valid text information of the short text to be processed and improving the accuracy of the determined valid text information.
[0072] In one embodiment, determining the valid text information of the short text to be processed based on auxiliary information word segmentation and the final matching result includes:
[0073] Determine the final matching results' order and position, and then determine the effective word sequence based on the order.
[0074] Determine the position of the auxiliary information segmentation within the effective word sequence;
[0075] The auxiliary information segmentation and the effective word sequence are merged based on their positions in the effective word sequence.
[0076] This embodiment can accurately merge auxiliary information word segmentation and final matching results to further improve the accuracy of the determined effective text information.
[0077] In one example, reference Figure 4As shown, after a real short text work order (such as the short text to be processed) is processed by the short text data processing method used for hospital logistics operations, the output is a vector composed of "1, 2, 3, 4, 5, 6, a, b, c, d" (the number and order of elements are determined by the actual short text content). However, this is not yet practically applicable. It is necessary to combine auxiliary information with main information (such as the validity in the final matching result) so that the final output is a vector containing only numbers. For example, "The faucet in the 3rd changing room on the 2nd floor of Building 6 is leaking" becomes "6\floor\2\floor\northeast\3\changing room\faucet\leaking" after custom word segmentation, with the corresponding pattern vector being [c,2,b,3,a,c,5,6,7]. The final output should be the pattern [c2,b3a,c5,6,7], corresponding to "6\floor\2nd floor northeast corner\3 changing room\faucet\leaking". The challenge lies in how computers (such as short text data processing terminals) accurately combine auxiliary information segmentation with primary information segmentation. This example uses the "Basic Model of Chinese Language Expression" to address this issue, and discusses different scenarios as follows:
[0078] (1) Auxiliary information segmentation is located at the beginning or end of the sentence.
[0079] Multiple (usually only one) consecutive auxiliary information segments at the beginning of the sentence are directly merged (regardless of the encoding category), and then merged with the nearest main information segment. The encoding of the merged content is the original encoding of the merged main information segment (e.g., ...). Figure 5 (As shown). When the auxiliary information segment is at the end of the sentence, it is directly merged with the nearest main information segment, and the process is exactly the same as at the beginning of the sentence.
[0080] (2) Auxiliary information segmentation is located in the sentence
[0081] Targeting directional words
[0082] Locative nouns mainly refer to nouns indicating east, west, south, north, inside, outside, up, down, and center, as well as their combined derivatives, such as east side, southeast side, southeastern direction, and inside. Their main characteristic is that they have no meaning when alone and require other content words as a reference. In most cases, they conform to a modifier-head structure like "the southeast side of ××". Therefore, this paper combines locative words in sentences with the keywords preceding them, such as... Figure 6 As shown.
[0083] For ordinal numbers
[0084] Ordinal numbers, such as "first" and "second," can function as subjects (e.g., "The second row is mine"), objects (e.g., "I chose the second option"), modifiers (e.g., "We will implement the second plan"), and predicate nominatives (e.g., "He is second in our group"). Further extraction of results directly related to ordinal numbers—"second row," "second option," "second," and "third place"—leads to the general conclusion that ordinal numbers directly modify the content that follows them. Therefore, this paper stipulates that when an ordinal number is located in the middle of a sentence, it should be combined with the following keywords.
[0085] For numbers and letters
[0086] Individual numbers and letters have no practical meaning in a sentence and must be combined with other content. According to Chinese expression conventions, the direct content modified by both is placed after them. Therefore, this example stipulates that auxiliary keywords such as numbers and letters should be combined with the result that follows them, such as... Figure 7 As shown.
[0087] It should be noted that combining letters and numbers with the following keywords can ensure accuracy in most scenarios, but if the actual content has multiple semantic meanings, the result may still be incorrect. For example, in "The light in locker room 3 is broken," "3" can be interpreted as either "locker room" or "light tube."
[0088] In this example, precise segmentation can be achieved by extracting and segmenting the corresponding short text keywords. The corresponding short text data processing method for hospital logistics operations and maintenance has the following technical advantages:
[0089] (1) Processing flow
[0090] The technical process proposed in this example is suitable for precise semantic segmentation of short texts. It is neither minimal segmentation nor paragraph division, but rather phrase segmentation based on actual meaning. Furthermore, phrases can be categorized according to fixed patterns, facilitating subsequent statistical analysis and sentence restructuring.
[0091] (2) Keyword Classification
[0092] Conventional word segmentation methods include the part-of-speech tag for keywords, but cannot categorize them. This solution adds a classification dimension to the custom word segmentation model, in addition to the usual attributes. Phrases are divided into two main categories: "primary information" and "auxiliary information," with each category further subdivided into subcategories. After word segmentation, the text to be processed uses fuzzy matching to find complete results and corresponding types in a custom classification thesaurus.
[0093] (3) Keyword coding
[0094] Encoding "primary information" and "auxiliary information" using "numbers" and "letters" respectively facilitates the conversion of textual keywords into numbers and letters. This allows for pattern recognition of the input short text based on the combination of letters and numbers. It also resolves potential issues with disordered keyword order, reverse chronological order, or interjections in the input short text.
[0095] (4) Mode processing
[0096] Starting with Chinese expression habits, auxiliary phrases such as "locative words," "ordinal numbers," "numbers," and "letters" are combined with the keywords before and after them according to their own characteristics. This reduces the possibility of meaningless word segmentation after direct word segmentation, increases the semantic integrity of effective word segmentation, and also makes subsequent processing more convenient.
[0097] In one embodiment, before determining the classification lexicon based on the corpus, the method further includes:
[0098] Collect statements that occur within a specified time period for the described object to obtain statement sources, and construct a corpus based on the statement sources.
[0099] The time period mentioned above can include a longer period of the past 3 years.
[0100] As one example, the described object includes a hospital.
[0101] This embodiment can guarantee the accuracy of the constructed corpus.
[0102] In one example, taking a large tertiary hospital as the subject of description, we can collect accumulated data (i.e., statements describing the subject) from recent years for a specific area of the hospital to build a corpus.
[0103] In one embodiment, after reorganizing the classified lexicon according to a preset word segmentation method to obtain a preliminary word segmentation lexicon, performing word segmentation on the corpus based on the preliminary word segmentation lexicon, performing word frequency statistics on each keyword after word segmentation, and adding the statistical results to the preliminary word segmentation lexicon to obtain a custom word segmentation lexicon, the method further includes:
[0104] Obtain a public stop word library, and construct a custom stop word library based on the public stop word library and the classification word library; the custom stop word library is used to clean the word segmentation results of full-mode word segmentation.
[0105] Specifically, the original short text usually contains some content that is irrelevant to text processing. These contents are collectively referred to as stop words. Stop words not only reduce the efficiency of text processing but also interfere with the determination of word segmentation categories and pattern determination. The number of commonly used public stop words is about 1800. After determination, public stop words are conventional stop words. If not filtered, semantic loss and errors will occur in specific fields. For example, stop words such as "down", "up", "one", etc. have clear practical meanings in the field of hospital logistics operation and maintenance, and they must be retained. This embodiment can obtain a custom stop word library in the following way:
[0106] Custom stop word library = Public stop word library - Public stop word library ∩ Custom classification word library
[0107] In the formula, "∩" represents taking the intersection.
[0108] In one embodiment, the cleaning of the word segmentation results of full-mode word segmentation includes:
[0109] Using the custom stop word library to identify stop words in the word segmentation results of full-mode word segmentation. After removing the identified stop words, removing duplicate words in the word segmentation results of full-mode word segmentation to obtain multiple valid items, and determining the identified stop words as auxiliary information word segmentation.
[0110] In the word segmentation results of full-mode word segmentation, words that appear in the custom stop word library are stop words.
[0111] The cleaning performed in this embodiment has a better cleaning effect.
[0112] Refer to Figure 8 as shown in Figure 8 A schematic structural diagram of a short text data processing device for hospital logistics operation and maintenance in one embodiment, including:
[0113] The first determination module 10 is used to determine the classification word library according to the corpus; the classification word library is used to describe the word categories of each word included in the corpus;
[0114] The recombination module 20 is used to recombine the classification word library according to a preset word segmentation method to obtain a preliminary word segmentation word library, perform word segmentation processing on the corpus according to the preliminary word segmentation word library, perform word frequency statistics on each keyword after word segmentation, and add the statistical results to the preliminary word segmentation word library respectively to obtain a custom word segmentation word library;
[0115] The word segmentation module 30 is used to perform full-mode word segmentation on the short text to be processed using the custom word segmentation dictionary, clean the word segmentation results of the full-mode word segmentation, obtain auxiliary information word segmentation and multiple valid items of the short text to be processed, match each valid item in the classification dictionary using fuzzy matching, obtain the initial matching results of each valid item, and select the matching result with the highest word frequency from the initial matching results of each valid item as the final matching result of each valid item.
[0116] The second determining module 40 is used to determine the valid text information of the short text to be processed based on the auxiliary information word segmentation and the final matching result.
[0117] In one embodiment, the second determining module is used to:
[0118] Determine the final matching results' order and position, and then determine the effective word sequence based on the order.
[0119] Determine the position of the auxiliary information segmentation within the effective word sequence;
[0120] The auxiliary information segmentation and the effective word sequence are merged based on their positions in the effective word sequence.
[0121] Specific limitations regarding the short text data processing device for hospital logistics operations and maintenance can be found in the limitations regarding the short text data processing method for hospital logistics operations and maintenance described above, and will not be repeated here. Each module in the aforementioned short text data processing device for hospital logistics operations and maintenance can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in the computer device in hardware form, or stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0122] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 9As shown, the computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. 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 network interface is used to communicate with external terminals via a network connection. When executed by the processor, the computer program implements a short text data processing method for hospital logistics operations and maintenance. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad mounted on the computer device casing, or an external keyboard, touchpad, or mouse.
[0123] Those skilled in the art will understand that Figure 9 The 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.
[0124] Based on the examples described above, in one embodiment a computer device is also provided, the computer device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, it implements any of the short text data processing methods for hospital logistics operations and maintenance as described in the above embodiments.
[0125] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a non-volatile computer-readable storage medium. For example, in the embodiments of the present invention, the program can be stored in the storage medium of a computer system and executed by at least one processor in the computer system to implement the processes of the embodiments of the short text data processing method for hospital logistics operations described above. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.
[0126] Accordingly, in one embodiment, a computer storage medium is also provided, which is a computer-readable storage medium having a computer program stored thereon, wherein the program, when executed by a processor, implements any of the short text data processing methods for hospital logistics operations and maintenance as described in the above embodiments.
[0127] 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 specification.
[0128] It should be noted that the terms "first," "second," and "third" used in the embodiments of this application are merely to distinguish similar objects and do not represent a specific order of objects. It is understood that "first," "second," and "third" can be interchanged in a specific order or sequence where permitted. It should be understood that the objects distinguished by "first," "second," and "third" can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in an order other than those illustrated or described herein.
[0129] The terms "comprising" and "having," and any variations thereof, in this application are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or device that includes a series of steps or modules is not limited to the steps or modules listed, but may optionally include steps or modules not listed, or may optionally include other steps or modules inherent to such processes, methods, products, or devices.
[0130] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. 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 patent application should be determined by the appended claims.
Claims
1. A short text data processing method for hospital logistics operations and maintenance, characterized in that, Includes the following steps: S10, determine a classification lexicon based on the corpus; the classification lexicon is used to describe the word category of each word included in the corpus; S20, the classified vocabulary is reorganized according to the preset word segmentation method to obtain a preliminary word segmentation vocabulary. The corpus is segmented according to the preliminary word segmentation vocabulary. The word frequency of each keyword after segmentation is statistically analyzed. The statistical results are added to the preliminary word segmentation vocabulary to obtain a custom word segmentation vocabulary. S30, the custom word segmentation dictionary is used to perform full-mode word segmentation on the short text to be processed. The word segmentation results of the full-mode word segmentation are cleaned to obtain auxiliary information word segmentation and multiple valid items of the short text to be processed. Fuzzy matching is used to match each valid item in the classification dictionary to obtain the initial matching results of each valid item. The matching result with the highest word frequency in the initial matching results of each valid item is selected as the final matching result of each valid item. S40, determine the effective text information of the short text to be processed based on auxiliary information word segmentation and final matching results, including: Determine the final matching results' order and position, and then determine the effective word sequence based on the order. Determine the position of the auxiliary information segmentation within the effective word sequence; The auxiliary information segmentation and the effective word sequence are merged based on the position of the auxiliary information segmentation in the effective word sequence; The auxiliary information for word segmentation includes location, ordinal number, digit, and letter; When auxiliary information is segmented in the sentence, for locative words, the locative word in the sentence is combined with the keyword preceding it; for ordinal numbers, the ordinal number in the sentence is combined with the keyword following it; for numbers and letters, the auxiliary keywords of number and letter types in the sentence are combined with the result following them.
2. The short text data processing method for hospital logistics operation and maintenance according to claim 1, characterized in that, Before determining the classification lexicon based on the corpus, the following steps are also included: Collect statements that occur within a specified time period for the described object to obtain statement sources, and construct a corpus based on the statement sources.
3. The short text data processing method for hospital logistics operation and maintenance according to claim 2, characterized in that, The described objects include hospitals.
4. The short text data processing method for hospital logistics operation and maintenance according to any one of claims 1 to 3, characterized in that, The process of reorganizing the classified vocabulary according to a preset word segmentation method to obtain a preliminary word segmentation vocabulary, performing word segmentation on the corpus based on the preliminary word segmentation vocabulary, performing word frequency statistics on each keyword after word segmentation, and adding the statistical results to the preliminary word segmentation vocabulary to obtain a custom word segmentation vocabulary, further includes: Obtain a public stop word library, and construct a custom stop word library based on the public stop word library and the classification word library; the custom stop word library is used to clean the word segmentation results of full-mode word segmentation.
5. The short text data processing method for hospital logistics operation and maintenance according to claim 4, characterized in that, The cleaning of the word segmentation results for the full-mode word segmentation includes: The custom stop word library is used to identify stop words in the full-mode word segmentation results. After removing the identified stop words, duplicate words in the full-mode word segmentation results are removed to obtain multiple valid items. The identified stop words are then determined as auxiliary information for word segmentation.
6. A short text data processing device for hospital logistics operation and maintenance, characterized in that, include: The first determining module is used to determine a classification lexicon based on the corpus; the classification lexicon is used to describe the word category of each word included in the corpus; The reorganization module is used to reorganize the classified word library according to a preset word segmentation method to obtain a preliminary word segmentation word library, perform word segmentation processing on the corpus based on the preliminary word segmentation word library, perform word frequency statistics on each keyword after word segmentation, and add the statistical results to the preliminary word segmentation word library to obtain a custom word segmentation word library; The word segmentation module is used to perform full-mode word segmentation on the short text to be processed using the custom word segmentation dictionary, clean the word segmentation results of the full-mode word segmentation, obtain auxiliary information word segmentation and multiple valid items of the short text to be processed, match each valid item in the classification dictionary using fuzzy matching, obtain the initial matching results of each valid item, and select the matching result with the highest word frequency from the initial matching results of each valid item as the final matching result of each valid item. The second determining module is used to determine the valid text information of the short text to be processed based on auxiliary information word segmentation and the final matching result, including: Determine the final matching results' order and position, and then determine the effective word sequence based on the order. Determine the position of the auxiliary information segmentation within the effective word sequence; The auxiliary information segmentation and the effective word sequence are merged based on the position of the auxiliary information segmentation in the effective word sequence; The auxiliary information for word segmentation includes location, ordinal number, digit, and letter; When auxiliary information is segmented in the sentence, for locative words, the locative word in the sentence is combined with the keyword preceding it; for ordinal numbers, the ordinal number in the sentence is combined with the keyword following it; for numbers and letters, the auxiliary keywords of number and letter types in the sentence are combined with the result following them.
7. A computer device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, 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 5.
8. A computer-readable storage medium having stored thereon 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 5.