Keyword search method and device and search engine
A keyword search and keyword technology, applied in the field of information search, can solve the problems of slow keyword speed and large resource occupation, and achieve the effect of reducing index size, occupying less resources, and saving memory space
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0078] This embodiment provides a method for constructing an inverted dictionary tree, which is used to combine the dictionary tree with the inverted index. The method comprises the steps of:
[0079] Step 1: Obtain a document, split the document into several keywords through a word segmentation algorithm, each of the keywords is composed of multiple characters, and the order of all the characters forming each of the keywords is the character order; The above characters can be letters, numbers or letters, etc.
[0080] Step 2: Set the root node and several character nodes of the dictionary inverted tree, wherein the number of character nodes set is the same as the number of characters of keywords.
[0081] Step 3: Starting from the root node, dispose a key of the split on the character nodes of the branch according to the character order, and then connect the character nodes passed on the path to form a branch of the dictionary inverted tree branch.
[0082] Step 4: Set the...
Embodiment 2
[0101] This embodiment provides a keyword search method on the basis of Embodiment 1, which is used to quickly search for the corresponding document number for the keyword, so as to solve the problem of using a linear inverted index to search for keywords that need to traverse the entire index, which takes a long time , The problem of slow speed.
[0102] like image 3 As shown, the keyword search method described in this embodiment includes the following steps:
[0103] Step 301: Obtain keywords and dictionary inverted trees.
[0104] Wherein, the keywords can be obtained by splitting the document. The dictionary inverted tree can be obtained by the construction method described in Embodiment 1. Specifically, the dictionary inverted tree includes: a root node, at least one branch connected to the root node, wherein each branch It is formed by sequentially connecting a plurality of character nodes, each character node contains a character, and each end character node of the...
Embodiment 3
[0124] In the process of the keyword search method described in the above embodiments, an automatic error correction function is also provided. When there are mistakes such as typos, multiple words, and missing words in the keywords entered by the user, the dictionary inverted tree will automatically correct them and prompt the user with the words that are most similar to the keywords.
[0125] One possible implementation is to adjust the number of similar keywords prompted by automatic error correction by controlling the number of words that are allowed to be wrong in the keywords to be searched. Further, after the user enters the keyword search, when it is judged that there is no target, then it is detected whether there are errors such as typos, multiple characters, or missing characters in the keywords entered by the user, that is, it is judged that the character on a branch in the dictionary inverted tree is consistent with the target. Whether the number of different char...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


