Relevance based inverted indexing
The relevance-based inverted indexing mechanism addresses the inefficiencies of conventional methods by excluding irrelevant terms and ranking documents by relevance, enhancing data efficiency and retrieval accuracy.
Patent Information
- Application Number
- PCT/CN2024/084270
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-03-28
- Publication Date
- 2025-10-02
AI Technical Summary
Conventional inverted index techniques in information retrieval systems include all extracted terms in the index list, regardless of relevance, leading to increased data volume and computational complexity.
A relevance-based inverted indexing mechanism that constructs an index list by considering the relevance between terms and documents, excluding irrelevant terms and ranking document identifications based on relevance levels, using AI models to generate relevant terms and relevance levels.
Reduces data volume and computational cost while improving the accuracy and efficiency of information retrieval by focusing on relevant terms and documents, simplifying complex ranking algorithms.
Smart Images

Figure CN2024084270_02102025_PF_FP_ABST
Abstract
Description
RELEVANCE BASED INVERTED INDEXINGBACKGROUND
[0001] Various information retrieval systems, such as search engines, have been developed for retrieving targeted information from a database storing a giant amount of information. In order to find the targeted information efficiently, indexes may be built for the database. The indexes for the database may play a similar role as a directory for a dictionary. Inverted index technique is a type of common indexing technique. The inverted index technique may reversely map a term to a list of documents containing the term. The inverted index technique may facilitate retrieving targeted documents for a certain query efficiently, and thus is widely applied in various information retrieval scenarios.SUMMARY
[0002] This Summary is provided to introduce a selection of concepts that are further described below in the Detailed Description. It is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
[0003] Embodiments of the present disclosure propose methods, apparatuses and non-transitory computer-readable medium for relevance based inverted indexing. Multiple groups of terms may be obtained, wherein each group of terms is relevant to a document among multiple documents. Relevance levels between terms among the group of terms and the document may be obtained. An inverted index list comprising multiple entries may be constructed, wherein each entry may comprise a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents may be ranked according to relevance levels between the term and documents among the group of documents.
[0004] It should be noted that the above one or more aspects comprise the features hereinafter fully described and particularly pointed out in the claims. The following description and the drawings set forth in detail certain illustrative features of the one or more aspects. These features are only indicative of the various ways in which the principles of various aspects may be implemented, and this disclosure is intended to include all such aspects and their equivalents.BRIEF DESCRIPTION OF THE DRAWINGS
[0005] The disclosed aspects will hereinafter be described in conjunction with the appended drawings that are provided to illustrate and not to limit the disclosed aspects.
[0006] FIG. 1 illustrates an exemplary process for relevance based inverted indexing according to an embodiment.
[0007] FIG. 2 illustrates a schematic diagram of relevant terms and relevance levels generated for multiple documents according to an embodiment.
[0008] FIG. 3 illustrates an exemplary process of generating relevant terms and relevance levels by a term and relevance generating model according to an embodiment.
[0009] FIG. 4 illustrates an exemplary process of generating relevant terms by a term generating model according to an embodiment.
[0010] FIG. 5 illustrates an exemplary process of generating relevant terms by a relevance classifying model according to an embodiment.
[0011] FIG. 6 illustrates an exemplary process of generating relevance levels by a relevance measuring model according to an embodiment.
[0012] FIG. 7 illustrates an exemplary process of constructing an inverted index list based on relevant terms and relevance levels according to an embodiment.
[0013] FIG. 8 illustrates an exemplary process of constructing a respective inverted index list through dividing original documents according to an embodiment.
[0014] FIG. 9 illustrates a schematic diagram of additionally indicating a document section type in an inverted index list according to an embodiment.
[0015] FIG. 10 illustrates an exemplary process of performing information retrieval by utilizing an inverted index list according to an embodiment.
[0016] FIG. 11 illustrates a flowchart of an exemplary method for relevance based inverted indexing according to an embodiment.
[0017] FIG. 12 illustrates an exemplary apparatus for relevance based inverted indexing according to an embodiment.
[0018] FIG. 13 illustrates an exemplary apparatus for relevance based inverted indexing according to an embodiment.DETAILED DESCRIPTION
[0019] The present disclosure will now be discussed with reference to several exemplary implementations. It is to be understood that these implementations are discussed only for enabling those skilled in the art to better understand and thus implement the embodiments of the present disclosure, rather than suggesting any limitations on the scope of the present disclosure.
[0020] Inverted index technique may be used by an information retrieval system, such as, a search engine, to perform information retrieval for a database storing a giant amount of documents. A kernel step of the inverted index technique is to construct an inverted index list. Conventionally, in order to construct the inverted index list, documents stored in the database are traversed respectively to extract terms. Then, the extracted terms are built into the inverted index list. The inverted index list may comprise multiple entries, wherein each entry may map a term of the extracted terms to a group of documents containing the term. The group of documents are usually ranked according to popularities. When an information retrieval process is performed, the information retrieval system may find targeted documents from the database by utilizing the inverted index list.
[0021] Embodiments of the present disclosure propose a mechanism for relevance based inverted indexing, in order to efficiently and accurately perform information retrieval for a database storing multiple documents. According to the proposed relevance based inverted indexing mechanism, relevance between a term and a document is well considered in the process of constructing an inverted index list.
[0022] In an aspect, the inverted index list constructed according to the proposed mechanism may comprise multiple entries, wherein each entry may correspond to a term being relevant to at least one document among the multiple documents. In this way, only terms being relevant to at least one document are built into the inverted index list, while terms being not relevant to any document are excluded. Thus, as compared to the conventional mechanisms that build all extracted terms, no matter whether being relevant to a document, into the inverted index list, the number of terms in the inverted index list constructed according to the proposed mechanism is decreased.
[0023] Moreover, each entry in the inverted index list constructed according to the proposed mechanism may record identifications of a group of documents to which the corresponding term is relevant. In this way, for each term, only identifications of documents being relevant to the term are recorded, while identifications of documents being not relevant to the term are excluded. As compared to the conventional mechanisms that record, for a term, identifications of all documents containing the term, no matter whether the documents and the term are relevant to each other, the number of identifications of documents recorded for each term in the inverted index list constructed according to the proposed mechanism is decreased.
[0024] Reducing terms and recorded identifications of documents for each term may facilitate reducing the overall data volume in the inverted index list. By reducing the overall data volume, the proposed mechanism may achieve technical effects of saving memory space for the inverted index list and increasing computing speed of an information retrieval process performed by utilizing the inverted index list.
[0025] In an aspect, in each entry in the inverted index list constructed according to the proposed mechanism, identifications of a group of documents in the entry are ranked according to relevance levels between a corresponding term of the entry and documents among the group of documents. Ranking the identifications of the group of documents according to the relevance levels in the inverted index list may facilitate generating information retrieval results comprising most relevant documents. By providing information retrieval results that comprise the most relevant documents, the proposed mechanism may achieve a technical effect of improving accuracy of information retrieval results.
[0026] The conventional mechanisms usually rank documents for each term according to popularities in the inverted index list. In order to retrieve more relevant documents when performing an information retrieval process, some conventional mechanisms further perform complex relevance ranking algorithms to assign documents more relevant to the term with higher ranks. As compared to the conventional mechanisms, since identifications of a group of documents are ranked in each entry in the inverted index list according to relevance levels in the proposed mechanism, the complex relevance ranking algorithms may be simplified or avoided. By simplifying or avoiding the complex relevance ranking algorithms, the proposed mechanism may achieve a technical effect of reducing overall computing cost.
[0027] In an aspect, relevant terms and / or relevance levels for constructing the inverted index list may be generated by various AI models. In an example, these AI models may be implemented by any pre-trained universal AI models, and the relevant terms and / or relevance levels may be further used to train one or more lightweight target models. In another example, these AI models may be implemented by any specialized AI models that are specially trained to perform tasks of generating relevant terms and / or relevance levels.
[0028] In an aspect, after the inverted index list is constructed, an information retrieval process may be performed by utilizing the inverted index list.
[0029] FIG. 1 illustrates an exemplary process 100 for relevance based inverted indexing according to an embodiment. The process 100 may be performed for an information retrieval system, e.g., a search engine. Generally, the upper part of the process 100 relates to constructing an inverted index list 140, and the lower part of the process 100 relates to performing an information retrieval process by utilizing the constructed inverted index list 140.
[0030] The information retrieval system may be designed for retrieving information from a database. The information may be stored in the database in a form of “document” . A document may refer to a data object stored in the database, e.g., a text document, an image, a webpage, etc. As illustrated in FIG. 1, multiple documents 110 may be stored in the database.
[0031] For each document among the documents 110, a group of terms originating from the document and being relevant to the document may be generated. A term may refer to a word item, which may comprise a single word, a phrase constituted by a group of words, etc. In the present disclosure, a document and a term originating from the document may be referred to as a pair of term and document or a pair of document and term. A pair of term and document may be determined as being relevant when there is a semantic relevance or association between the term and the document. A term appeared in a document is not necessarily related to the document. For example, for a webpage introducing a book “Gone with the Wind” by Margaret Mitchell, the term “wind” may be not relevant to the webpage as lacking of semantic relevance or association with the webpage, even though it actually appears many times in the webpage. Moreover, some meaningless terms appearing in a document but conveying less substantial semantic information are also not relevant to the document. For example, such meaningless terms may be prepositions such as “in” , “on” , “at” , “with” , “of” , etc., articles such as “a” , “an” , “the” , “this” , “that” , etc., numerals such as “one” , “multiple” , etc., and any other forms of meaningless words or phrases.
[0032] In an example, the above discussed terms may comprise named entities, fixed phrases, and other specialized terms, etc. A named entity may refer to a word or a group of words assigned with particular meaning, such as, title of a book, name of a person, name of an organization, etc. A fixed phrase may refer to a group of words that are conventionally combined together in a fixed manner, such as, various verbal phrases, e.g., “turn on” “get back” , “take over” , etc. Building these named entities, and fixed phrases, etc., into the inverted index list 140 may facilitate resulting more accurate information retrieval results.
[0033] Each term that is originated from a document and being relevant to the document may be referred to as a relevant term in the present disclosure. As illustrated in FIG. 1, multiple groups of relevant terms 120 may be generated for the multiple documents 110, respectively. The multiple groups of relevant terms 120 may be generated by several exemplary manners, e.g., by utilizing a term and relevance generating model as discussed with reference to FIG. 3, by utilizing a term generating model as discussed with reference to FIG. 4, by utilizing a relevance classifying model as discussed with reference to FIG. 5, and by any other possible term generating manners that are not detailed in the present disclosure, such as, manual labeling, etc. In an example, the models for generating the relevant terms may be implemented by any pre-trained universal AI models, e.g., a large language model (LLM) . In this case, the documents 110 and relevant terms 120 may be further used to train one or more target models which might be lightweight as compared to the pre-trained universal AI models, as indicated at 180. In another example, the models for generating the relevant terms may be implemented by any specialized AI models that are specially trained to generate relevant terms.
[0034] The generated multiple groups of relevant terms 120 may be used as basis for constructing the inverted index list 140. The inverted index list 140 may comprise multiple entries. Each entry in the inverted index list 140 may correspond to a term among the multiple groups of relevant terms 120. Each entry may record identifications of a group of documents to which the term is relevant among the multiple documents. An identification of a document may refer to any identifying information, e.g., ID, for uniquely distinguishing the document from other documents stored in the database. Throughout the present disclosure, a number following “Doc” / “document” is an exemplary identifying information. For example, “Doc 1” represent a document with ID “1” , “Doc 2” represent a document with ID “2” , and so on. As exemplarily indicated by entry 1 of the inverted index list 140, term 1 may correspond to a group of documents with identifications of 1-6, term 2 may correspond to a group of documents with identifications of 2-7, etc. Other entries may similarly indicate a correspondence between a term and a group of documents to which the term is relevant.
[0035] Based on the multiple documents 110 and the multiple groups of relevant terms 120, relevance levels 130 may be generated. A relevance level is an indicator for measuring how much a pair of term and document is relevant to each other. A pair of term and document being more relevant to each other may have a higher relevance level, and a pair of term and document being less relevant to each other may have a lower relevance level. In an example, the relevance level may be embodied as a relevance score ranged from 0 to 1. In another example, the relevance level may be embodied as any measurements other than a relevance score as used in the present disclosure.
[0036] The relevance levels 130 may be generated based on measurements relating to several factors. A main factor affecting the relevance level between a pair of term and document is how much the term is semantically relevant or associated to the document. In an example, other factors affecting the relevance level may comprise such as whether a term is tightly relevant to a main topic of the document, a position where the term appears in the document, a count for the term appearing in the document, rating or comments from users for the term and the document, etc.
[0037] The relevance levels 130 may be generated by several exemplary manners, e.g., by utilizing a term and relevance generating model as discussed with reference to FIG. 3, by utilizing a relevance measuring model as discussed with reference to FIG. 6, and by any other possible relevance level generating manners that are not detailed in the present disclosure, such as, manual labeling, etc. In an example, the models for generating the relevance levels may be implemented by any pre-trained universal AI models, e.g., a LLM. In this case, the documents 110, relevant terms 120 and relevance levels 130 may be further used to train one or more target models which might be lightweight as compared to the pre-trained universal AI models, as indicated at 180. In another example, the models for generating the relevance levels may be implemented by any specialized AI models that are specially trained to generate relevance levels.
[0038] The relevance levels 130 may be used as basis for constructing the inverted index list 140. In each entry, identifications of a group of documents in the entry to which a corresponding term of the entry is relevant are ranked according to relevance levels. A document among the group of documents having a higher relevance level with the term may have a higher rank, and a document among the group of documents having a lower relevance level with the term may have a lower rank. As exemplarily illustrated in FIG. 1, for entry 1 in the inverted index list140, the identifications of the group of documents corresponding to term 1 are ranked as {Doc 1, Doc 3, Doc 5, Doc 2, Doc 4, Doc 6…} . The ranking may be determined based on such a fact indicated by the relevance levels 130: the relevance level between document 1 and term 1 is higher than the relevance level between document 3 and term 1; the relevance level between document 3 and term 1 is higher than the relevance level between document 5 and term 1; and so on.
[0039] After the inverted index list 140 is constructed, an information retrieval process may be performed by utilizing the inverted index list. The information retrieval system may receive, at 150, a query. The information retrieval system may perform, at 160, an information retrieval process by utilizing the inverted index list 140. The information retrieval system may then return, at 170, information retrieval results.
[0040] FIG. 2 illustrates a schematic diagram 200 of relevant terms and relevance levels generated for multiple documents according to an embodiment.
[0041] FIG. 2 illustrates multiple documents 210, identified as document 1 to document N. The documents 210 may correspond to the documents 110 as discussed with reference to FIG. 1. For each document among the multiple documents 210, a group of relevant terms and relevance levels may be generated. As illustrated in FIG. 2, a group of relevant terms 220-1 and relevance levels 230-1 may be generated for document 1, a group of relevant terms 220-2 and relevance levels 230-2 may be generated for document 2, …, and a group of relevant terms 220-N and relevance levels 230-N may be generated for document N.
[0042] Taking the group of relevant terms 220-1 as an example, the group of relevant terms 220-1 may comprise multiple terms “term 1” , “term 2” , “term 3” , “term 4” , etc. Each term among the group of relevant terms 220-1 is originated from document 1 and is relevant to document 1.
[0043] Taking relevance levels 230-1 as an example, the relevance levels 230-1 may comprise relevance levels for multiple pairs of terms among the group of relevant terms 220-1 and document 1. Each relevance level may measure how much a term among the group of relevant terms 220-1 and the document 1 is relevant to each other. As exemplarily illustrated in FIG. 2, according to the relevance levels 230-1, the relevance level between document 1 and term 1 is 0.95, the relevance level between document 1 and term 2 is 0.60, the relevance level between document 1 and term 3 is 0.80, the relevance level between document 1 and term 4 is 0.96, etc. It should be noted that, although FIG. 2 illustrates the relevance levels in an exemplary form of relevance scores ranged from 0 to 1, in other examples, the relevance levels may be embodied in various other forms. For example, the relevance levels may be embodied as relevance scores falling in numerical ranges other than the range of [0, 1] , the relevance levels may be embodied as relevance orders such as a first relevance level, a second relevance level, …, and so on.
[0044] In an example, for each of the documents 210, relevant terms and relevance levels may be generated jointly, as discussed below with reference to FIG. 3. In another example, for each document 210, relevant terms and relevance levels may be generated separately, as discussed below with reference to FIG. 4 to FIG. 6.
[0045] FIG. 3 illustrates an exemplary process 300 of generating relevant terms and relevance levels by a term and relevance generating model according to an embodiment.
[0046] FIG. 3 illustrates multiple documents 310-1 to 310-N, wherein these documents may correspond to the documents 110 as discussed with reference to FIG. 1, and the documents 210 as discussed with reference to FIG. 2. As illustrated in FIG. 3, each document may be processed by a term and relevance generating model 320, to generate a group of terms and relevance levels for the document. For example, the term and relevance generating model 320 may generate a group of terms and relevance levels 330-1 for document 1 310-1, a group of terms and relevance levels 330-2 for document 2 310-2, …, a group of terms and relevance levels 330-N for document N 310-N. Taking document 1 310-1 as an example, the group of terms and relevance levels 330-1 comprise term 1, term 2, term 3, term 4, …, wherein each term is relevant to document 1 310-1. The group of terms and relevance levels 330-1 also comprise a relevance score 0.95 between term 1 and document 1, a relevance score 0.60 between term 2 and document 1, a relevance score 0.80 between term 3 and document 1, a relevance score 0.96 between term 4 and document 1, etc. The multiple groups of terms and relevance levels generated for the multiple documents respectively may be obtained by an information retrieval system for constructing an inverted index list.
[0047] The term and relevance generating model 320 may be a generative model, which may receive a document and generate a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document.
[0048] In an example, the term and relevance generating model 320 may be implemented by any pre-trained universal AI models, e.g., a LLM. The LLM is a type of large-scale language model having the ability of effectively achieving general-purpose language understanding and generation. The LLM may acquire this ability by using massive amounts of data to learn a large amount of parameters during training. The processing performed by the LLM usually consume a large amount of computing resources. In this case, the relevant terms and relevance levels generated by the LLM may be further used as training data for training a lightweight target model. The training data may comprise multiple training data pairs. Each training data pair may comprise a document, e.g., document 1 310-1, as an input, and a group of terms and relevance levels, e.g. 330-1, generated by the term and relevance generating model 320 as outputs. The lightweight target model may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, a RNN architecture, etc. The lightweight target model, after being trained with the training data, may be applied to perform a task of generating, for a document, a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document. Applying such a lightweight target model may achieve a technical effect of saving computing cost and improving computing efficiency as compared to directly applying the LLM.
[0049] In another example, the term and relevance generating model 320 may be implemented by any specialized AI models that are specially trained to perform a task of generating, for a document, a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document. In this case, the term and relevance generating model 320 may be trained with multiple training data pairs. Each training data pair may comprise a document as an input, and a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document as outputs. These specialized trained models may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, and a RNN architecture, etc.
[0050] FIG. 4 illustrates an exemplary process 400 of generating relevant terms by a term generating model according to an embodiment.
[0051] FIG. 4 illustrates multiple documents 410-1 to 410-N, these documents may correspond to the documents 110 as discussed with reference to FIG. 1, and the documents 210 as discussed with reference to FIG. 2. As illustrated in FIG. 4, each document may be processed by a term generating model 420, to generate a group of terms for the document. For example, the term generating model 420 may generate a group of terms 430-1 for document 1 410-1, a group of terms for document 2 410-2, …, a group of terms 430-N for document N 410-N. Taking document 1 410-1 as an example, the group of terms 430-1 comprises term 1, term 2, term 3, term 4, …, wherein each term is relevant to document 1 410-1. The multiple groups of terms generated for the multiple documents respectively may be acquired by an information retrieval system for constructing an inverted index list.
[0052] The term generating model 420 may be a generative model, which may receive a document and generate a group of terms being relevant to the document.
[0053] In an example, the term generating model 420 may be implemented by any pre-trained universal AI models, e.g., the above discussed LLM. In this case, the relevant terms generated by the LLM may be further used as training data for training a lightweight target model. The training data may comprise multiple training data pairs. Each training data pair may comprise a document, e.g., document 1 410-1, as an input, and a group of terms, e.g. 430-1, generated by the term generating model 420 as outputs. The lightweight target model may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, and a RNN architecture, etc. The lightweight target model, after being trained with the training data, may be applied to perform a task of generating, for a document, a group of terms being relevant to the document. Applying such a lightweight target model may achieve a technical effect of saving computing cost and improving computing efficiency as compared to directly applying the LLM.
[0054] In another example, the term generating model 420 may be implemented by any specialized AI models that are specially trained to perform a task of generating, for a document, a group of terms being relevant to the document. In this case, the term and generating model 420 may be trained with multiple training data pairs. Each training data pair may comprise a document as an input, and a group of terms being relevant to the document as outputs. These specialized trained models may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, a RNN architecture, etc.
[0055] FIG. 5 illustrates an exemplary process 500 of generating relevant terms by a relevance classifying model according to an embodiment.
[0056] FIG. 5 illustrates multiple documents 510-1 to 510-N, these documents may correspond to the documents 110 as discussed with reference to FIG. 1, and the documents 210 as discussed with reference to FIG. 2. For each document, term extracting 520 may be performed, to generate a group of extracted original terms. Term extracting 520 may be implemented by any known term extracting operations, such as tokenization for breaking each sentence in a document into multiple single words and reorganizing the single words into one or more word groups, etc. For example, document 1 510-1 may be a webpage introducing a book titled “Gone with the Wind” . After the term extracting 520 is performed to document 1 510-1, the extracted original terms 530-1 may comprise many words and phrases relating to the title, e.g., “gone” , “with” , “the” , “wind” , “gone with” , “the wind” , “with the wind” , “gone with the wind” , etc. Among the extracted original terms 530-1, some words and phrases, e.g., “gone” , “wind” , etc., are actually not semantically relevant or associated to document 1 510-1, and some words and phrases, e.g., “with” , “the” , etc., are actually meaningless. In this case, the proposed mechanism proposes to further process the extracted original terms, to filtering out a large amount of irrelevant and / meaningless original terms.
[0057] As illustrated in FIG. 5, each group of original terms and the corresponding document from which the group of original terms is extracted may be provided to a relevance classifying model 540. The relevance classifying model 540 may perform a classifying task to classify an original term as being relevant to or not relevant to a document from which the original term is extracted. For example, relevance classifying results generated by the relevance classifying model 540 for document 1 and a group of original terms 530-1 may indicate whether each original term among the group of original terms 530-1 is relevant to document 1 or not. Based on the relevance classifying results generated by the relevance classifying model 540, terms among the group of original terms 530-1 that are classified as being relevant to document 1 may be selected from the group of original terms 530-1 to form a group of relevant terms 550-1. Multiple groups of relevant terms generated for the multiple documents may be used to construct an inverted index list.
[0058] The relevance classifying model 540 may be a classifying model, which may receive a document and a term originating from the document, and generate a classifying result indicating whether the document and the term are relevant to each other or not.
[0059] In an example, the relevance classifying model 540 may be implemented by any pre-trained universal AI models, e.g., the above discussed LLM. In another example, the relevance classifying model 540 may be implemented by any specialized AI models that are specially trained to perform a task of generating, for a pair of term and document, a relevance classifying result. For example, the relevance classifying model 540 may be implemented with a neutral network (NN) model (e.g., Transformer, BERT, etc., ) , a support vector machine (SVM) model, a decision tree (DT) model, etc., that may be used to perform a classification task.
[0060] FIG. 6 illustrates an exemplary process 600 of generating relevance levels by a relevance measuring model according to an embodiment.
[0061] As illustrated in FIG. 6, each document and a group of terms being relevant to the document may be provided to the relevance measuring model 620. The documents as discussed with reference to FIG. 6 may correspond to the documents 110 as discussed with reference to FIG. 1, and the documents 210 as discussed with reference to FIG. 2. In an example, a group of terms being relevant to a document may be generated through the relevant terms generating operations as discussed with reference to FIG. 4 or FIG. 5.
[0062] For a document, the relevance measuring model 620 may generate relevance levels, e.g., relevance scores, between terms among a group of terms generated for the document and the document based on the document and the group of terms being relevant to the document 610. As illustrated in FIG. 6, the relevance score between term 1 and document 1 is 0.95, the relevance score between term 2 and document 1 is 0.60, the relevance score between term 3 and document 1 is 0.80, the relevance score between term 4 and document 1 is 0.96, etc.
[0063] The relevance measuring model 620 may be a generative model, which may receive a document and a group of terms being relevant to the document, and generate relevance levels between terms among the group of terms and the document.
[0064] In an example, the relevance measuring model 620 may be implemented by any pre-trained universal AI models, e.g., the above discussed LLM. In this case, the relevance levels generated by the LLM may be further used as training data for training a lightweight target model. The training data may comprise multiple training data pairs. Each training data pair may comprise a document and a group of terms being relevant to the document, e.g., 610-1 as an input, and relevance levels between terms among the group of terms and the document, e.g., 630-1, as outputs. The lightweight target model may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, a RNN architecture, etc. The lightweight target model, after being trained with the training data, may be applied to perform a task of generating, for a document and a group of terms being relevant to the document, relevance levels between terms among the group of terms and the document. Applying such a lightweight target model may achieve a technical effect of saving computing cost and improving computing efficiency as compared to directly applying the LLM.
[0065] In another example, the relevance measuring model 620 may be implemented by any specialized AI models that are specially trained to perform a task of generating, for a document and a group of terms being relevant to the document, relevance levels between terms among the group of terms and the document. In this case, the relevance measuring model 620 may be trained with multiple training data pairs. Each training data pair may comprise a document and a group of terms being relevant to the document as inputs, and relevance levels between terms among the group of terms and the document as outputs. These specialized trained models may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, and a RNN architecture, etc.
[0066] FIG. 7 illustrates an exemplary process 700 of constructing an inverted index list based on relevant terms and relevance levels according to an embodiment. The exemplary process 700 describes how to build entries in an inverted index list based the obtained data 710. The obtained data 710 comprises, for each document, a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document. In an example, the relevant terms and / or relevance levels included in the obtained data 710 may be generated through the relevant terms and / or relevance levels generating operations as discussed with reference to FIG. 3 to FIG. 6.
[0067] As exemplarily illustrated through the obtained data 710, some common terms are usually relevant to different documents. Taking term 1 as an example, it may be determined based on the obtained data 710 that term 1 is relevant to document 1, term 1 is relevant to document 2, term 1 is relevant to document 3 (not illustrated in FIG. 7 for simplicity) , term 1 is relevant to document 5 (not illustrated in FIG. 7 for simplicity) , …, etc. Documents to which a term is relevant may constitute a group of documents. For example, for term 1, documents 1, 2, 3, 5, etc. may constitute a group of documents, as illustrated through data 720.
[0068] Moreover, based on the obtained data 710, relevance level between a pair of term and document may be determined. The relevance levels between multiple pairs of term and document may be compared to each other. Then, the group of documents to which the term is relevant may be ranked according to the comparisons for the relevance levels.
[0069] For example, for term 1, it may be determined that: the relevance level between term 1 and document 1 is higher than the relevance level between term 1 and document 3 (the relevance level between term 1 and document 3 is not illustrated in FIG. 7 for simplicity) ; the relevance level between term 1 and document 3 is higher than the relevance level between term 1 and document 5 (the relevance level between term 1 and document 5 is not illustrated in FIG. 7 for simplicity) ; the relevance level between term 1 and document 5 is higher than the relevance level between term 1 and document 2, …, etc. Thus, for term 1, the group of documents may be ranked as {document 1, document 3, document 5, document 2, …} , as illustrated through the data 720.
[0070] Based on the data 720, an inverted index list 730 may be constructed. The inverted index list 730 may comprise multiple entries. Each entry in the inverted index list 730 may correspond to a term among the terms in the data 720. Each entry may record identifications of a group of documents to which a corresponding term of the entry is relevant. The identifications of the group of documents may be ranked according to relevance levels.
[0071] It should be noted that, the data 720 is illustrated in FIG. 7 for the purpose of explaining the process of constructing the inverted index list 730 based on the data 710. In an example, the data 720 may be intermediate data during performing the process 700.
[0072] FIG. 8 and FIG. 9 relate to an exemplary scenario wherein documents stored in a database, for which information retrieval is to be performed by an information retrieval system, have a specific document structure. In this scenario, through the operations discussed with reference to FIG. 8 and FIG. 9, the information retrieval system may support flexibly perform an information retrieval process for a specific document section.
[0073] FIG. 8 illustrates an exemplary process 800 of constructing a respective inverted index list through dividing original documents according to an embodiment. As illustrated in FIG. 8, multiple original documents are stored in the database. The multiple original documents may have a specific document structure. For example, the original documents may be papers that include multiple sections, such as title, abstract, body, etc. Structural dividing operations may be performed to the original documents respectively. An original document 810-1 may be divided into a first section 820-1 comprising title of the original document 810-1, a second section 830-1 comprising abstract of the original document 810-1, and a third section 840-1 comprising body of the original document 810-1. Other original documents 810-2 to 810-M may be similarly divided respectively, to generate corresponding title sections 820-2 to 820-M, abstract sections 830-2 to 830-M, and body sections 840-2 to 840-M. Each of the divided sections 820-1 to 820-M may have a document section type of “title” . Each of the divided sections 830-1 to 830-M may have a document section type of “abstract” . Each of the divided sections 840-1 to 840-M may have a document section type of “body” . These divided sections may be reorganized according to the document section types. For example, sections 820-1, 820-2, …and 820-M, each having a document section type of “title” , may be reorganized as a first collection of documents 850-1. Sections 830-1, 830-2, …and 830-M, each having a document section type of “abstract” , may be reorganized as a second collection of documents 850-2. Sections 840-1, 840-2, …and 840-M, each having a document section type of “body” , may be reorganized as a third collection of documents 850-3.
[0074] An inverted index list may be generated separately for each of the three collections of documents. For example, an inverted index list 860-1 may be generated for the first collection of documents 850-1, an inverted index list 860-2 may be generated for the second collection of documents 850-2, and an inverted index list 860-3 may be generated for the third collection of documents 850-3. When constructing a corresponding inverted index list for a collection of documents, each section in the collection of documents may be treated as a document among the multiple documents as discussed above with reference to FIG. 1 to FIG. 7.
[0075] By constructing multiple inverted index lists corresponding to different document section types respectively, the information retrieval system may support performing the information retrieval process for a certain part of documents. For example, if a user designates to perform information retrieving in the title section, the information retrieval system may correspondingly invoke the inverted index list 860-1 to perform the information retrieval process.
[0076] FIG. 9 illustrates a schematic diagram 900 of additionally indicating a document section type in an inverted index list according to an embodiment. As illustrated in FIG. 9, an additional field, “Document Section Type” , may be added in an inverted index list to indicate at least one document section type for each document among a group of documents in each entry. For example, as shown in FIG. 9, in entry 1 of the inverted index list, the “Document Section Type” field for document 1 has values “Abstract” and “Body” , indicating that term 1 is originated from the abstract section and body section of document 1.
[0077] By adding the field “Document Section Type” in the inverted index list, the information retrieval system may support performing the information retrieval process for a certain part of documents. For example, if a user designates to perform information retrieving in the title section, the information retrieval system may only retrieve documents with values of the field “Document Section Type” comprising “Title” .
[0078] FIG. 10 illustrates an exemplary process 1000 of performing information retrieval by utilizing an inverted index list according to an embodiment. The exemplary process 1000 may be performed by an information retrieval system.
[0079] An inverted index list 1010 may be constructed through the exemplary operations as discussed above with reference to FIG. 2 to FIG. 8. As illustrated in FIG. 10, the inverted index list 1010 comprises multiple entries. Each of the multiple entries comprises a term and identifications of a group of documents to which the term is relevant. The identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents.
[0080] The information retrieval system may receive a query 1020. The query 1020 may be in any form, such as a word, a phrase, a sentence, etc. The information retrieval system may search, in the inverted index list 1010, for one or more terms that are matched with the query, as illustrated at 1040. For example, the information retrieval system may find that the term 2 is matched with the query 1020. The information retrieval system may then return a group of documents according to the identifications {Doc 4, Doc 7, Doc 6, Doc 3, Doc 5, Doc 2, …} corresponding to term 2, as information retrieval results generated for the query 1020, as illustrated at 1050.
[0081] In an example, the information retrieval system may find that more than one term is matched with the query 1020. In this case, more than one group of documents corresponding respectively to the more than one term may be returned as the information retrieval results.
[0082] In an example, optionally, the query 1020 may be pre-processed, to facilitate accurately finding matched terms in the inverted index list. At 1030, the query 1020 may be per-processed to generate one or more search phrases. Pre-processing the query 1020 may comprise performing sematic analysis to the query 1020. Each search phrase generated through performing the sematic analysis may be one single word or a group of words being semantically associated to the query 1020. In an example, the pre-processing may be performed by a query analyzing model. The query analyzing model may be a generative model that generates semantically associated search phrases based on a received query. In an example, the query analyzing model may be implemented by any pre-trained universal AI models, e.g., the above discussed LLM. In another example, the query analyzing model may be implemented by any specialized AI models that are specially trained to perform a task of generating, for a query, one or more search phrases being semantically associated to the query. For example, these specialized trained models may employ any suitable model architecture, e.g., an Encoder-Decoder architecture, a LSTM architecture, a RNN architecture, etc.
[0083] The information retrieval system may perform the searching at 1040 with the one or more search phrases generated at 1030. The information retrieval system may search, for each search phrase, in the inverted index list 1010, for one or more terms that are matched with the search phrase. The information retrieval system may return at least one group of documents corresponding respectively to the searched one or more terms.
[0084] FIG. 11 illustrates a flowchart of an exemplary method 1100 for relevance based inverted indexing according to an embodiment.
[0085] At 1110, multiple groups of terms may be obtained, wherein each group of terms is relevant to a document among multiple documents.
[0086] At 1120, relevance levels between terms among the group of terms and the document may be obtained.
[0087] At 1130, an inverted index list comprising multiple entries may be constructed, wherein each entry may comprise a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents may be ranked according to relevance levels between the term and documents among the group of documents.
[0088] In an implementation, the group of terms and the relevance levels between terms among the group of terms and the document are generated by a term and relevance generating model for the document.
[0089] The term and relevance generating model may be trained with multiple training data pairs, each training data pair may comprise a document as an input, and a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document as outputs.
[0090] In an implementation, the method 1100 may further comprise: training a target model with multiple training data pairs, each training data pair may comprise a document among the multiple documents as an input, and one group of terms among the multiple groups of terms being relevant to the document and relevance levels between the document and terms among the group of terms as outputs.
[0091] In an implementation, the obtaining multiple groups of terms may comprise: acquiring the multiple groups of terms that are generated by a term generating model for the multiple documents respectively.
[0092] In an implementation, the obtaining multiple groups of terms may comprise: acquiring multiple groups of original terms that are extracted from the multiple documents respectively; receiving relevance classifying results generated by a relevance classifying model, the relevance classifying model being for classifying an original term as being relevant to or not relevant to a document from which the original term is extracted; and selecting, from the multiple groups of original terms, the multiple groups of terms based on the relevance classifying results.
[0093] In an implementation, the obtaining relevance levels may comprise: receiving the relevance levels that are generated by a relevance measuring model for the terms among the group of terms and the document.
[0094] In an implementation, the multiple documents may correspond to a same document section type.
[0095] In an implementation, each entry in the inverted index list may further indicate a document section type for each document among a group of documents in the entry.
[0096] In an implementation, the method 1100 may further comprise: receiving a query; searching, in the inverted index list, for one or more terms matched with the query; and returning one or more groups of documents corresponding respectively to the one or more terms.
[0097] The searching, in the inverted index list, for one or more terms matched with the query may comprise: pre-processing the query by a query pre-processing model to generate one or more search phrases; and for each of the one or more search phrases, searching, in the inverted index list, for terms matched with the search phrase.
[0098] It should be appreciated that the method 1100 may further comprise any steps / processes for relevance based inverted indexing according to the embodiments of the present disclosure as mentioned above.
[0099] FIG. 12 illustrates an exemplary apparatus 1200 for relevance based inverted indexing according to an embodiment. The apparatus 1200 may comprise: a term obtaining module 1210, for obtaining multiple groups of terms, each group of terms being relevant to a document among multiple documents; a relevance level obtaining module 1220, for obtaining relevance levels between terms among the group of terms and the document; and an inverted index list constructing module 1230, for constructing an inverted index list comprising multiple entries, wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents. Moreover, the apparatus 1200 may also comprise any other modules configured for performing any steps and operations of the methods for relevance based inverted indexing according to the embodiments of the present disclosure as mentioned above.
[0100] FIG. 13 illustrates an exemplary apparatus 1300 for relevance based inverted indexing according to an embodiment. The apparatus 1300 may comprise at least one processor 1310 and a memory 1320 storing computer-executable instructions. When the computer-executable instructions are executed, the at least one processor 1310 may: obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents; obtain relevance levels between terms among the group of terms and the document; and construct an inverted index list comprising multiple entries, wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents. The at least one processor 1310 may be further configured for performing any operations of the methods for relevance based inverted indexing according to the embodiments of the present disclosure as mentioned above.
[0101] The embodiments of the present disclosure may be embodied in a non-transitory computer-readable medium for relevance based inverted indexing. The non-transitory computer readable medium may include instructions that, when executed, cause one or more processors to: obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents; obtain relevance levels between terms among the group of terms and the document; and construct an inverted index list comprising multiple entries, wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents. The instructions, when executed, may further cause one or more processors to perform any operations of the methods for relevance based inverted indexing according to the embodiments of the present disclosure as mentioned above.
[0102] The embodiments of the present disclosure may be embodied in a computer program product for relevance based inverted indexing. The computer program product may include instructions that, when executed, cause at least one processor to: obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents; obtain relevance levels between terms among the group of terms and the document; and construct an inverted index list comprising multiple entries, wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents. The instructions, when executed, may further cause the at least one processor to perform any operations of the methods for relevance based inverted indexing according to the embodiments of the present disclosure as mentioned above.
[0103] It should be appreciated that all the operations in the methods described above are merely exemplary, and the present disclosure is not limited to any operations in the methods or orders of these operations, and should cover all other equivalents under the same or similar concepts.
[0104] It should also be appreciated that all the modules in the apparatuses described above may be implemented in various approaches. These modules may be implemented as hardware, software, or a combination thereof. Moreover, any of these modules may be further functionally divided into sub-modules or combined together.
[0105] Processors have been described in connection with various apparatuses and methods. These processors may be implemented using electronic hardware, computer software, or any combination thereof. Whether such processors are implemented as hardware or software will depend upon the particular application and overall design constraints imposed on the system. By way of example, a processor, any portion of a processor, or any combination of processors presented in the present disclosure may be implemented with a micro-processor, micro-controller, digital signal processor (DSP) , a field-programmable gate array (FPGA) , a programmable logic device (PLD) , a state machine, gated logic, discrete hardware circuits, and other suitable processing components configured to perform the various functions described in the present disclosure. The functionality of a processor, any portion of a processor, or any combination of processors presented in the present disclosure may be implemented with software being executed by a microprocessor, micro-controller, DSP, or other suitable platform.
[0106] Software shall be construed broadly to mean instructions, instruction sets, code, code segments, program code, programs, subprograms, software modules, applications, software applications, software packages, routines, subroutines, objects, threads of execution, procedures, functions, etc. The software may reside on a computer-readable medium. A computer-readable medium may include, by way of example, memory such as a magnetic storage device (e.g., hard disk, floppy disk, magnetic strip) , an optical disk, a smart card, a flash memory device, random access memory (RAM) , read only memory (ROM) , programmable ROM (PROM) , erasable PROM (EPROM) , electrically erasable PROM (EEPROM) , a register, or a removable disk. Although a memory is shown as being separate from the processor in various aspects presented in this disclosure, the memory may also be internal to the processor (e.g., a cache or a register) .
[0107] Moreover, the articles “a” and “an” as used in this specification and the appended claims should generally be construed to mean “one” or “one or more” unless specified otherwise or clear from the context to be directed to a singular form.
[0108] The previous description is provided to enable any person skilled in the art to practice the various aspects described herein. Various modifications to these aspects will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other aspects. Thus, the claims are not intended to be limited to the aspects shown herein. All structural and functional equivalents to the elements of the various aspects described throughout the present disclosure that are known or later come to be known to those of ordinary skilled in the art are intended to be encompassed by the claims.
Claims
1.A method for relevance based inverted indexing, comprising:obtaining multiple groups of terms, each group of terms being relevant to a document among multiple documents;obtaining relevance levels between terms among the group of terms and the document; andconstructing an inverted index list comprising multiple entries,wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents.2.The method of claim 1, wherein the group of terms and the relevance levels between terms among the group of terms and the document are generated by a term and relevance generating model for the document.3.The method of claim 2, wherein the term and relevance generating model is trained with multiple training data pairs, each training data pair comprising a document as an input, and a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document as outputs.4.The method of claim 2, further comprising:training a target model with multiple training data pairs, each training data pair comprising a document among the multiple documents as an input, and one group of terms among the multiple groups of terms being relevant to the document and relevance levels between the document and terms among the group of terms as outputs.5.The method of claim 1, wherein the obtaining multiple groups of terms comprises:acquiring the multiple groups of terms that are generated by a term generating model for the multiple documents respectively.6.The method of claim 1, wherein the obtaining multiple groups of terms comprises:acquiring multiple groups of original terms that are extracted from the multiple documents respectively;receiving relevance classifying results generated by a relevance classifying model, the relevance classifying model being for classifying an original term as being relevant to or not relevant to a document from which the original term is extracted; andselecting, from the multiple groups of original terms, the multiple groups of terms based on the relevance classifying results.7.The method of claim 1, wherein the obtaining relevance levels comprises:receiving the relevance levels that are generated by a relevance measuring model for the terms among the group of terms and the document.8.The method of claim 1, wherein the multiple documents correspond to a same document section type.9.The method of claim 1, wherein each entry in the inverted index list further indicates a document section type for each document among a group of documents in the entry.10.The method of claim 1, further comprising:receiving a query;searching, in the inverted index list, for one or more terms matched with the query; andreturning one or more groups of documents corresponding respectively to the one or more terms.11.The method of claim 10, wherein the searching, in the inverted index list, for one or more terms matched with the query comprises:pre-processing the query by a query pre-processing model to generate one or more search phrases; andfor each of the one or more search phrases, searching, in the inverted index list, for terms matched with the search phrase.12.An apparatus for relevance based inverted indexing, comprising:at least one processor; anda memory storing computer-executable instructions that, when executed, cause the at least one processor to:obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents;obtain relevance levels between terms among the group of terms and the document; andconstruct an inverted index list comprising multiple entries,wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents.13.The apparatus of claim 12, wherein the group of terms and the relevance levels between terms among the group of terms and the document are generated by a term and relevance generating model for the document.14.The apparatus of claim 13, wherein the term and relevance generating model is trained with multiple training data pairs, each training data pair comprising a document as an input, and a group of terms being relevant to the document and relevance levels between terms among the group of terms and the document as outputs.15.The apparatus of claim 13, wherein the computer-executable instructions, when executed, further cause the at least one processor to:train a target model with multiple training data pairs, each training data pair comprising a document among the multiple documents as an input, and one group of terms among the multiple groups of terms being relevant to the document and relevance levels between the document and terms among the group of terms as outputs.16.The apparatus of claim 12, wherein the obtaining multiple groups of terms comprises:acquiring the multiple groups of terms that are generated by a term generating model for the multiple documents respectively.17.The apparatus of claim 12, wherein the obtaining multiple groups of terms comprises:acquiring multiple groups of original terms that are extracted from the multiple documents respectively;receiving relevance classifying results generated by a relevance classifying model, the relevance classifying model being for classifying an original term as being relevant to or not relevant to a document from which the original term is extracted; andselecting, from the multiple groups of original terms, the multiple groups of terms based on the relevance classifying results.18.The apparatus of claim 12, wherein the obtaining relevance levels comprises:receiving the relevance levels that are generated by a relevance measuring model for the terms among the group of terms and the document.19.A non-transitory computer-readable medium, comprising instructions that, when executed, cause at least one processor to:obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents;obtain relevance levels between terms among the group of terms and the document; andconstruct an inverted index list comprising multiple entries,wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents.20.A computer program product, comprising instructions that, when executed, cause at least one processor to:obtain multiple groups of terms, each group of terms being relevant to a document among multiple documents;obtain relevance levels between terms among the group of terms and the document; andconstruct an inverted index list comprising multiple entries,wherein each entry comprises a term among the multiple groups of terms and identifications of a group of documents to which the term is relevant among the multiple documents, and the identifications of the group of documents are ranked according to relevance levels between the term and documents among the group of documents.