A word segmentation retrieval method, system, device and storage medium
By combining custom and default word segmenters to construct merge sets and remainder sets, the problem of supporting new words in word segmentation retrieval is solved, enabling real-time updates and efficient retrieval of hot words, and improving the applicability and accuracy of word segmentation retrieval.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SICHUAN COVER MEDIA TECH CO LTD
- Filing Date
- 2023-11-20
- Publication Date
- 2026-07-14
Smart Images

Figure CN117453987B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of information retrieval technology, specifically relating to a word segmentation retrieval method, system, device, and storage medium. Background Technology
[0002] With the rapid development of internet technology, new styles and forms of online media are emerging endlessly, and various trending information is boundless. Word segmentation technology, as a preprocessing method for search engines, has been widely applied in various aspects of internet retrieval, primarily text retrieval. When performing word segmentation retrieval, a pre-set default thesaurus can be used; however, this default thesaurus does not support new vocabulary on the internet. Although custom words can be added, this is a one-time operation because all subsequent operations involve refreshing historical data, leading to increased memory consumption and performance loss. Summary of the Invention
[0003] The purpose of this invention is to provide a word segmentation retrieval method, system, device, and storage medium to solve the aforementioned problems existing in the prior art.
[0004] To achieve the above objectives, the present invention adopts the following technical solution:
[0005] Firstly, a word segmentation retrieval method is provided, including:
[0006] Get the target text input by the user;
[0007] The target text is input into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. The custom word segmenter is the first word segmenter pre-built by the ElasticSearch engine after associating with a custom dictionary. The custom dictionary contains several custom words.
[0008] The target text is input into the default word segmenter for word segmentation processing to obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter is the second word segmenter pre-built by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default words.
[0009] Extract the corresponding custom word segments as hot words from the custom word segmentation results in sequence;
[0010] For the extracted hot words, each default word segmentation result is traversed in the default word segmentation result to determine multiple consecutive default word segments corresponding to the hot words. The number of default word segments in the multiple consecutive default word segments is the minimum and they contain the hot words after being merged.
[0011] Multiple consecutive default word segments corresponding to hot words are merged to obtain the corresponding merged word groups. The merged word groups are included in the merge set. Default word segments that are completely contained in hot words are removed from multiple consecutive default word segments, and the remaining default word segments are included in the remaining set.
[0012] The ElasticSearch engine retrieval script is constructed based on the merge set and the remainder set, and the ElasticSearch engine is used to retrieve the corresponding information according to the ElasticSearch engine retrieval script.
[0013] In one possible design, the method further includes:
[0014] After compiling the merged phrases corresponding to the current hot words into the merge set, the current hot words are removed from the custom word segmentation results to obtain the updated custom word segmentation results. Default words that are completely contained in the hot words from multiple consecutive default word segments are removed from the default word segmentation results to obtain the updated default word segmentation results.
[0015] New trending words are extracted based on the updated custom word segmentation results, and the corresponding merged word groups are determined based on the updated default word segmentation results. This process is repeated until all custom word segments in the custom word segmentation results have been extracted.
[0016] In one possible design, both the first and second word segmenters are IK word segmenters.
[0017] In one possible design, the method further includes, before inputting the target text into a custom word segmenter for word segmentation, the following:
[0018] Collect a number of original words;
[0019] The original words are segmented using the default word segmenter to obtain the corresponding original word segmentation results.
[0020] When the original word segmentation result is a complete original word, it is determined that there is a default word segmentation in the default dictionary that is the same as the corresponding original word; otherwise, it is determined that there is no default word segmentation in the default dictionary that is the same as the corresponding original word. In this case, the corresponding original word is entered into the custom dictionary as a custom word.
[0021] In one possible design, before inputting the target text into the custom word segmenter for word segmentation, the method further includes: initializing the custom word segmenter with a custom dictionary, including constructing a trie of the custom dictionary, and using a forward iterative finest-grained segmentation algorithm to match and associate the custom word segmenter with the trie.
[0022] In one possible design, the ElasticSearch engine retrieval script built based on the merge set and the remaining set includes:
[0023] Build a merged phrase query script using the ElasticSearch engine's phrase query component match_phrase;
[0024] Build the tokenization term script for the remaining set using the term component of the ElasticSearch engine;
[0025] The phrase query script and the word segmentation term script are connected through the ElasticSearch engine's should component to obtain the ElasticSearch engine retrieval script.
[0026] Secondly, a word segmentation retrieval system is provided, comprising a text acquisition unit, a first word segmentation unit, a second word segmentation unit, a word extraction unit, a word matching unit, a word organization unit, and a word retrieval unit, wherein:
[0027] The text acquisition unit is used to acquire the target text input by the user.
[0028] The first word segmentation unit is used to input the target text into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. The custom word segmenter is the first word segmenter pre-built by the ElasticSearch engine after associating with a custom dictionary. The custom dictionary contains several custom words.
[0029] The second word segmentation unit is used to input the target text into the default word segmenter for word segmentation processing and obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter is the second word segmenter pre-configured by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default words.
[0030] The word segmentation extraction unit is used to extract the corresponding custom words as hot words from the custom word segmentation results in sequence;
[0031] The word segmentation matching unit is used to traverse each default word segmentation result in the extracted hot words and determine multiple consecutive default word segments corresponding to the hot words. The number of default word segments in the multiple consecutive default word segments is the minimum and the merged result contains the hot words.
[0032] The word segmentation and sorting unit is used to merge multiple consecutive default word segments corresponding to hot words to obtain the corresponding merged word groups. The merged word groups are then compiled into the merge set. Default word segments that are completely contained in hot words are removed from multiple consecutive default word segments, and the remaining default word segments are compiled into the remaining set.
[0033] The word segmentation retrieval unit is used to construct an ElasticSearch engine retrieval script based on the merge set and the remainder set, and then use the ElasticSearch engine to retrieve the corresponding information according to the ElasticSearch engine retrieval script.
[0034] Thirdly, a word segmentation retrieval device is provided, including:
[0035] Memory, used to store instructions;
[0036] A processor is configured to read instructions stored in the memory and execute the method described in any one of the first aspects above, according to the instructions.
[0037] Fourthly, a computer-readable storage medium is provided, on which instructions are stored, which, when executed on a computer, cause the computer to perform any of the methods described in the first aspect. A computer program product containing instructions is also provided, which, when executed on a computer, cause the computer to perform any of the methods described in the first aspect.
[0038] Beneficial Effects: This invention performs secondary word segmentation on the user-input target text based on a custom lexicon and a default lexicon, achieving a mapping from custom segmentation to default segmentation. Then, based on the custom segmentation results, it establishes a merged set of related terms and a residual set of differences within the default segmentation results. Finally, it uses the merged set and the residual set for Elasticsearch (ES) retrieval. This allows for compatibility with and hot updates of trending terms, improving ES word segmentation retrieval efficiency. This invention effectively supports word segmentation retrieval of trending terms, ensuring the applicability and accuracy of ES word segmentation retrieval for trending terms, and improving word segmentation retrieval performance with limited data. Attached Figure Description
[0039] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0040] Figure 1 This is a schematic diagram of the steps in the method of Embodiment 1 of the present invention;
[0041] Figure 2 This is a schematic diagram of the system configuration in Embodiment 2 of the present invention;
[0042] Figure 3 This is a schematic diagram of the device configuration in Embodiment 3 of the present invention. Detailed Implementation
[0043] It should be noted that the descriptions of these embodiments are intended to aid in understanding the invention and do not constitute a limitation thereof. The specific structural and functional details disclosed herein are merely for describing exemplary embodiments of the invention. However, the invention may be embodied in many alternative forms and should not be construed as being limited to the embodiments described herein.
[0044] It should be understood that, unless otherwise explicitly specified and limited, the term "connection" should be interpreted broadly. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium; it can be a connection within two components. Those skilled in the art can understand the specific meaning of the above terms in the embodiments according to the specific circumstances.
[0045] Specific details are provided in the following description to provide a complete understanding of the exemplary embodiments. However, those skilled in the art will understand that the exemplary embodiments can be implemented without these specific details. For example, the system may be shown in block diagrams to avoid obscuring the example with unnecessary details. In other embodiments, well-known processes, structures, and techniques may be shown without non-essential details to avoid obscuring the embodiments.
[0046] Example 1:
[0047] This embodiment provides a word segmentation retrieval method, which can be applied to corresponding word segmentation retrieval servers, such as... Figure 1 As shown, the method includes the following steps:
[0048] S1. Obtain the target text input by the user.
[0049] In practice, the target text entered by the user on the front end for retrieval is first obtained. The target text may contain relevant hot keywords.
[0050] S2. Input the target text into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom word segments arranged in sequence. The custom word segmenter is the first word segmenter pre-configured by the ElasticSearch engine after associating with the custom dictionary. The custom dictionary contains several custom word segments.
[0051] In practice, before inputting the target text into the custom word segmenter for word segmentation, it is necessary to collect a number of raw words. These raw words can be collected manually, through third-party interfaces, or by web crawling, to gather trending online terms such as "media asset library," "audit cloud," and "c-vision." Then, each raw word is segmented using a default word segmenter to obtain the corresponding raw word segmentation results. The default word segmenter can be either Elasticsearch's IK segmenter or the Jieba segmenter. When the raw word segmentation result is a complete raw word, it is determined that a default word segmentation identical to the corresponding raw word exists in the default word library; otherwise, it is determined that no default word segmentation identical to the corresponding raw word exists in the default word library. In this case, the corresponding raw word is entered into the custom word library as a custom word. For example, for a single original word "media asset library", when the default word library contains the default word segmentation "media asset library", the original word segmentation result of the default word segmenter on the original word "media asset library" is the complete "media asset library". However, when the default word library does not contain the default word segmentation "media asset library", the word segmentation result of the default word segmenter on the original word "media asset library" is "media", "asset", and "library", which is not the complete original word "media asset library". At this time, it can be determined that the original word "media asset library" is a popular online word that needs to be updated, and it is entered into the custom word library as a custom word segmentation. This process is repeated to build and update the custom word library.
[0052] Before inputting the target text into the custom word segmenter for word segmentation, it is necessary to initialize the custom word segmenter with a custom dictionary. The process includes building a trie of the custom dictionary and using a forward iterative finest-grained segmentation algorithm to match and associate the custom word segmenter with the trie, resulting in a custom word segmenter associated with the custom dictionary. The custom word segmenter can use the IK word segmenter pre-built in the ElasticSearch engine.
[0053] Then, a custom word segmenter associated with the custom thesaurus can be used to segment the target text, obtaining the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. For example, if the target text is "Media Asset Library is a digital asset management platform", when the custom word "Media Asset Library" exists in the custom thesaurus, the obtained custom word segmentation result will contain "Media Asset Library".
[0054] S3. Input the target text into the default word segmenter for word segmentation processing to obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default word segments arranged in sequence. The default word segmenter is the second word segmenter pre-configured by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default word segments.
[0055] In practice, the target text is input into a default word segmenter for word segmentation processing to obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter can be the ElasticSearch engine's pre-built IK word segmenter associated with the local default dictionary. For example, if the target text is "Media Asset Library is a digital asset management platform", and the local default dictionary contains the default words "media", "asset", "library", "is", "a", "digital", "asset", "management", and "platform", the obtained default word segmentation result will be "media", "asset", "library", "is", "a", "digital", "asset", "management", and "platform". Furthermore, the default word segmentation result avoids overlapping or duplicate word segmentation.
[0056] S4. Extract the corresponding custom word segments from the custom word segmentation results as hot words.
[0057] In practice, the corresponding custom word segments can be extracted sequentially from the custom word segmentation results as hot words for subsequent matching processing.
[0058] S5. For the extracted hot words, traverse each default word segmentation result in the default word segmentation result, determine multiple consecutive default word segments corresponding to the hot words, the number of default word segments of the multiple consecutive default word segments is the minimum, and the merged result contains the hot words.
[0059] In practice, for each hot word extracted, the default word segmentation results are traversed to determine multiple consecutive default word segmentations corresponding to the hot word. The number of default word segmentations in the multiple consecutive default word segmentations is minimized and the merged result contains the hot word. For example, if the hot word is "media asset library", then each of the multiple consecutive default word segmentations should contain at least one of "media", "asset", or "library".
[0060] S6. Merge multiple consecutive default word segments corresponding to hot words to obtain the corresponding merged word groups. Add the merged word groups to the merge set and remove the default word segments that are completely contained in the hot words from the multiple consecutive default word segments. Add the remaining default word segments to the remaining set.
[0061] In practice, multiple consecutive default word segments corresponding to hot keywords are merged to obtain corresponding merged word groups, which are then included in a merge set. For example, if the hot keyword is "media asset library" and multiple consecutive default word segments are "media", "asset", and "library", then "media", "asset", and "library" are merged to obtain the corresponding merged word group "media asset library". If multiple consecutive default word segments are "XX media", "asset", and "library XX", then the corresponding merged word group "XX media asset library XX" is obtained. Because the default thesaurus contains word segments such as "XX media" and "library XX", the custom thesaurus treats "media asset library" as a new word, which is equivalent to changing the default thesaurus. However, the word segmentation results in the dataset created by the default thesaurus do not change, so the merged word group must contain the original word segments.
[0062] After obtaining the merged word groups corresponding to the current hot words, the current hot words will be removed from the custom word segmentation results to obtain the updated custom word segmentation results. Then, the default word segments that are completely contained in the hot words in multiple consecutive default word segments will be removed from the default word segmentation results to obtain the updated default word segmentation results. Then, based on the updated custom word segmentation results and the updated default word segmentation results, steps S4-S6 will be executed again in a loop until the custom word segments in the custom word segmentation results are extracted, that is, the hot words are matched and compared in turn to obtain the final merged set and the remaining set. For example, if the current hot word is "media asset library", and its corresponding consecutive default word segments are "media", "asset", and "library", after obtaining the merged phrase "media asset library", "media asset library" is removed from the custom word segmentation results. "Media", "asset", and "library" that are completely included in the hot word "media asset library" are also removed from the default word segmentation results. Then, the next hot word is extracted from the updated custom word segmentation results for matching. Similarly, if the current hot word is "media asset library", and its corresponding consecutive default word segments are "XX media", "asset", and "library XX", after obtaining the merged phrase "XX media asset library XX", "media asset library" is removed from the custom word segmentation results. "Asset" that is completely included in the hot word "media asset library" is also removed from the default word segmentation results, while "XX media" and "library XX" are retained for use in the next hot word matching process to ensure correct handling of duplicate word segments. Then, the next hot word is extracted from the updated custom word segmentation results for matching. This process is repeated until all hot word matching is completed.
[0063] S7. Construct an ElasticSearch engine retrieval script based on the merged set and the remaining set, and then use the ElasticSearch engine to retrieve the corresponding information according to the ElasticSearch engine retrieval script.
[0064] In practice, the phrase query script for the merged set can be built using the ElasticSearch engine's phrase query component `match_phrase`, and the term segmentation script for the remaining set can be built using the ElasticSearch engine's `term` component. Then, the phrase query script and the term segmentation script are connected using the ElasticSearch engine's `should` component to obtain the ElasticSearch engine retrieval script. Finally, the ElasticSearch engine is used to perform the corresponding information retrieval based on the ElasticSearch engine retrieval script to obtain the corresponding information retrieval results.
[0065] The method in this embodiment can achieve compatibility and hot updates for hot words, improve the efficiency of ES word segmentation retrieval, effectively support word segmentation retrieval for hot words, ensure the applicability and accuracy of ES word segmentation retrieval for hot words, and improve the word segmentation retrieval effect under conditions of small data volume.
[0066] Example 2:
[0067] This embodiment provides a word segmentation retrieval system, such as Figure 2 As shown, it includes a text acquisition unit, a first word segmentation unit, a second word segmentation unit, a word extraction unit, a word matching unit, a word processing unit, and a word retrieval unit, wherein:
[0068] The text acquisition unit is used to acquire the target text input by the user.
[0069] The first word segmentation unit is used to input the target text into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. The custom word segmenter is the first word segmenter pre-built by the ElasticSearch engine after associating with a custom dictionary. The custom dictionary contains several custom words.
[0070] The second word segmentation unit is used to input the target text into the default word segmenter for word segmentation processing and obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter is the second word segmenter pre-configured by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default words.
[0071] The word segmentation extraction unit is used to extract the corresponding custom words as hot words from the custom word segmentation results in sequence;
[0072] The word segmentation matching unit is used to traverse each default word segmentation result in the extracted hot words and determine multiple consecutive default word segments corresponding to the hot words. The number of default word segments in the multiple consecutive default word segments is the minimum and the merged result contains the hot words.
[0073] The word segmentation and sorting unit is used to merge multiple consecutive default word segments corresponding to hot words to obtain the corresponding merged word groups. The merged word groups are then compiled into the merge set. Default word segments that are completely contained in hot words are removed from multiple consecutive default word segments, and the remaining default word segments are compiled into the remaining set.
[0074] The word segmentation retrieval unit is used to construct an ElasticSearch engine retrieval script based on the merge set and the remainder set, and then use the ElasticSearch engine to retrieve the corresponding information according to the ElasticSearch engine retrieval script.
[0075] Example 3:
[0076] This embodiment provides a word segmentation retrieval device, such as... Figure 3 As shown, at the hardware level, it includes:
[0077] The data interface is used to establish data communication between the processor and various user terminals.
[0078] Memory, used to store instructions;
[0079] The processor is used to read instructions stored in the memory and execute the word segmentation retrieval method in Embodiment 1 according to the instructions.
[0080] Optionally, the device also includes an internal bus. The processor, memory, and data interface can be interconnected via the internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc.
[0081] The memory may include, but is not limited to, random access memory (RAM), read-only memory (ROM), flash memory, first-in-first-out (FIFO) memory, and / or first-in-last-out (FILO) memory. The processor may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0082] Example 4:
[0083] This embodiment provides a computer-readable storage medium storing instructions. When these instructions are executed on a computer, the computer performs the word segmentation retrieval method described in Embodiment 1. The computer-readable storage medium refers to a data storage medium, which may include, but is not limited to, floppy disks, optical disks, hard disks, flash memory, USB flash drives, and / or Memory Sticks. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable systems.
[0084] This embodiment also provides a computer program product containing instructions that, when executed on a computer, cause the computer to perform the word segmentation retrieval method in Embodiment 1. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable system.
[0085] Finally, it should be noted that the above description is merely a preferred embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A word segmentation retrieval method, characterized in that, include: Get the target text input by the user; The target text is input into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. The custom word segmenter is the first word segmenter pre-built by the ElasticSearch engine after associating with a custom dictionary. The custom dictionary contains several custom words. The target text is input into the default word segmenter for word segmentation processing to obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter is the second word segmenter pre-built by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default words. Extract the corresponding custom word segments as hot words from the custom word segmentation results in sequence; For the extracted hot words, each default word segmentation result is traversed in the default word segmentation result to determine multiple consecutive default word segments corresponding to the hot words. The number of default word segments in the multiple consecutive default word segments is the minimum and they contain the hot words after being merged. Multiple consecutive default word segments corresponding to hot words are merged to obtain the corresponding merged word groups. The merged word groups are included in the merge set. Default word segments that are completely contained in hot words are removed from multiple consecutive default word segments, and the remaining default word segments are included in the remaining set. The process involves constructing an ElasticSearch engine retrieval script based on the merged set and the remainder set, and then using the ElasticSearch engine to retrieve the corresponding information based on the ElasticSearch engine retrieval script. This construction includes: building a phrase query script for the merged set using the ElasticSearch engine's phrase query component `match_phrase`; building a word segmentation term script for the remainder set using the ElasticSearch engine's term component; and connecting the phrase query script and the word segmentation term script using the ElasticSearch engine's `should` component to obtain the ElasticSearch engine retrieval script.
2. The word segmentation retrieval method according to claim 1, characterized in that, The method further includes: After compiling the merged phrases corresponding to the current hot words into the merge set, the current hot words are removed from the custom word segmentation results to obtain the updated custom word segmentation results. Default words that are completely contained in the hot words from multiple consecutive default word segments are removed from the default word segmentation results to obtain the updated default word segmentation results. New trending words are extracted based on the updated custom word segmentation results, and the corresponding merged word groups are determined based on the updated default word segmentation results. This process is repeated until all custom word segments in the custom word segmentation results have been extracted.
3. The word segmentation retrieval method according to claim 1, characterized in that, Both the first and second word segmenters use the IK word segmenter.
4. The word segmentation retrieval method according to claim 1, characterized in that, Before inputting the target text into a custom word segmenter for word segmentation, the method further includes: Collect a number of original words; The original words are segmented using the default word segmenter to obtain the corresponding original word segmentation results. When the original word segmentation result is a complete original word, it is determined that there is a default word segmentation in the default dictionary that is the same as the corresponding original word; otherwise, it is determined that there is no default word segmentation in the default dictionary that is the same as the corresponding original word. In this case, the corresponding original word is entered into the custom dictionary as a custom word.
5. The word segmentation retrieval method according to claim 4, characterized in that, Before inputting the target text into the custom word segmenter for word segmentation, the method further includes: initializing the custom word segmenter with a custom dictionary, including constructing a trie of the custom dictionary, and using a forward iterative finest-grained segmentation algorithm to match and associate the custom word segmenter with the trie.
6. A word segmentation retrieval system, characterized in that, It includes a text acquisition unit, a first word segmentation unit, a second word segmentation unit, a word extraction unit, a word matching unit, a word processing unit, and a word retrieval unit, wherein: The text acquisition unit is used to acquire the target text input by the user. The first word segmentation unit is used to input the target text into a custom word segmenter for word segmentation processing to obtain the corresponding custom word segmentation result. The custom word segmentation result contains multiple custom words arranged in sequence. The custom word segmenter is the first word segmenter pre-built by the ElasticSearch engine after associating with a custom dictionary. The custom dictionary contains several custom words. The second word segmentation unit is used to input the target text into the default word segmenter for word segmentation processing and obtain the corresponding default word segmentation result. The default word segmentation result contains multiple default words arranged in sequence. The default word segmenter is the second word segmenter pre-configured by the ElasticSearch engine after associating with the local default dictionary. The default dictionary contains several default words. The word segmentation extraction unit is used to extract the corresponding custom words as hot words from the custom word segmentation results in sequence; The word segmentation matching unit is used to traverse each default word segmentation result in the extracted hot words and determine multiple consecutive default word segments corresponding to the hot words. The number of default word segments in the multiple consecutive default word segments is the minimum and the merged result contains the hot words. The word segmentation and sorting unit is used to merge multiple consecutive default word segments corresponding to hot words to obtain the corresponding merged word groups. The merged word groups are then compiled into the merge set. Default word segments that are completely contained in hot words are removed from multiple consecutive default word segments, and the remaining default word segments are compiled into the remaining set. The word segmentation retrieval unit is used to construct an ElasticSearch engine retrieval script based on the merged set and the remainder set, and to perform corresponding information retrieval using the ElasticSearch engine according to the ElasticSearch engine retrieval script. The construction of the ElasticSearch engine retrieval script based on the merged set and the remainder set includes: constructing a phrase query script for the merged set using the ElasticSearch engine's phrase query component match_phrase; constructing a word segmentation term script for the remainder set using the ElasticSearch engine's term component; and connecting the phrase query script and the word segmentation term script using the ElasticSearch engine's should component to obtain the ElasticSearch engine retrieval script.
7. A word segmentation retrieval device, characterized in that, include: Memory, used to store instructions; A processor is configured to read instructions stored in the memory and execute the word segmentation retrieval method according to any one of claims 1-5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores instructions that, when executed on a computer, cause the computer to perform the word segmentation retrieval method according to any one of claims 1-5.