Indexing and searching of electronic message transmission thread sets

A method includes describing the thread configurations of a volume of well-ordered electronic message transmissions (EMT) and utilizing the thread configuration data to conduct selective searches of the EMT volume. An apparatus includes a thread processor and a query manager. The thread processor analyzes the EMT threads and records the thread configuration data. The query manager utilizes the thread configuration data to conduct selective searches of the EMT volume.

FIELD OF THE INVENTION

The present invention relates to the processing of electronic text generally.

BACKGROUND OF THE INVENTION

Since its introduction to the public in the late 20thcentury, email has become a popular and widely used form of communication both at home and in the workplace. In addition to the advantages email introduced to the realm of interpersonal communications, by making the delivery of written messages quicker and more convenient, email further introduced completely new benefits to the exchange of written messages.

For example, the “Reply” and “Forward” functions available to email users introduced the “discussion thread”. Reference is now made toFIG. 1, which depicts an email exchange process19by which a discussion thread is formed. An email discussion thread is started by the transmission of a single email message10(the root message), from Person X to Person Y, as indicated by arrow13. The content of email10is the text20written by Person X. This initial email transmission is defined as Round1of email exchange19.

Person Y then replies, as indicated by arrow15, to Person X, by using a conventional email “Reply” function. Use of the “Reply” function generates email11, which contains root message text20, and to which Person Y adds his reply text21. This first reply is defined as Round2of email exchange19.

Person X then replies to Person Y using the “Reply” function, as indicated by arrow17, in which case his reply email12contains root message text20, first reply text21and new reply text22. This second reply is defined as Round3of email exchange19.

One benefit of the email discussion thread is that it provides running documentation of a discussion occurring between two or more people. At any time it is possible to read the entire discussion thread beginning from the root message, and thus obtain a full picture of what was discussed, and which contributions to the discussion were made by whom, without a laborious search for documents.

Unfortunately, discussion threads significantly increase the volume of messages to be stored and processed by an email administration system. For example, the processes of indexing and searching message volumes become increasingly cumbersome with increasing message volume size.

SUMMARY OF THE INVENTION

The present invention provides a novel method of indexing and searching large volumes of electronic message transmissions (EMTs).

There is therefore provided, in accordance with a preferred embodiment of the present invention, a search engine including a compacting indexer and a query manager. The compacting indexer indexes well-ordered threads of electronic message transmissions (EMTs). The query manager searches through an index produced by the compacting indexer and identifies at least one qualifying EMT of a qualifying EMT thread as a search result when provided with a query.

Moreover, in accordance with a preferred embodiment of the present invention, the compacting indexer includes a thread processor to determine the configurations of the EMT threads and to generate a compact EMT volume for indexing into an index.

Further, in accordance with a preferred embodiment of the present invention, the thread processor includes a docID assigner, a compact EMT compiler and a thread configuration data compiler. The docID assigner assigns consecutive numerical IDs to the EMTs from meta-data associated with the EMTs. The compact EMT compiler generates a compact EMT for each numerical ID which is formed of the meta-data of the EMT and new content text added by the EMT to its thread. The thread configuration data compiler compiles thread configuration data for the EMT threads.

Still further, in accordance with a preferred embodiment of the present invention, the thread configuration data compiler includes a root EMT determiner and a last offspring determiner. The root EMT determiner determines a root EMT of the EMT thread. The last offspring determiner determines a last offspring EMT of each EMT belonging to the EMT thread.

Additionally, in accordance with a preferred embodiment of the present invention, the thread configuration data compiler also includes a thread type determiner to determine a thread type of each EMT thread.

Further, in accordance with a preferred embodiment of the present invention, the query manager includes a candidate enumerator, a postings iteration manager and an assessment unit. The candidate enumerator selects a candidate EMT for examination with respect to terms of the query and the EMT thread configurations. The postings iteration manager searches posting lists of the index for the terms. The assessment unit assesses the multiple qualifying EMTs against the query.

Further, in accordance with a preferred embodiment of the present invention, the assessment unit includes a candidate ranker which provides, per qualifying EMT thread, at least one qualifying EMT as a search result to the query according to a variable retrieval policy of the search engine. The retrieval policy is defined by the search engine or the user.

Further, in accordance with a preferred embodiment of the present invention, the retrieval policy dictates that the search result is either the chronologically first qualifying EMT in each qualifying EMT thread, the chronologically last qualifying EMT in each qualifying EMT thread, the highest scoring qualifying EMT in each qualifying EMT thread or all of the qualifying EMTs.

Alternatively, in accordance with a preferred embodiment of the present invention, the query manager includes a query processor and a virtual cursor layer. The query processor includes a postings iteration manager and an assessment unit. The query processor searches the posting lists of the index for the terms of the query. The assessment unit assesses the multiple qualifying EMTs against the query. The virtual cursor layer guides a candidate enumeration process to enumerate candidate EMTs with respect to the terms of the query and the EMT thread configurations.

Moreover, in accordance with a preferred embodiment of the present invention, the assessment unit includes a candidate ranker which provides, per qualifying EMT thread, at least one qualifying EMT as a search result to the query according to a variable retrieval policy of the search engine. The retrieval policy is defined by the search engine or the user.

Further, in accordance with a preferred embodiment of the present invention, the retrieval policy dictates that the search result is either the chronologically first qualifying EMT in each qualifying EMT thread, the chronologically last qualifying EMT in each qualifying EMT thread, the highest scoring qualifying EMT in each qualifying EMT thread or all of the qualifying EMTs.

There is also provided, in accordance with a preferred embodiment of the present invention, a method including representing an unmodified volume of EMT threads as a compact EMT volume, indexing the compact EMT volume into an index, searching the index, and returning EMT results from the unmodified volume.

Moreover, in accordance with a preferred embodiment of the present invention, the representing step includes associating, with a unique ID number assigned to each EMT in the unmodified volume, meta-data of the EMT and new content text added by each the EMT to its thread.

Further, in accordance with a preferred embodiment of the present invention, the indexing step includes distinguishing between occurrences of a term in the EMT meta-data and in the EMT content.

Still further, in accordance with a preferred embodiment of the present invention, the method also includes determining thread configuration data describing the EMT threads, and the searching step includes searching the index with the thread configuration data.

Additionally, in accordance with a preferred embodiment of the present invention, the determining step also includes analyzing the EMT threads to identify a root EMT of each EMT thread and a last offspring EMT of each EMT. The root EMT is the source EMT spawning the EMT thread. The last offspring EMT is the EMT having the highest the numerical ID of all EMTs referring to the EMT.

Additionally, in accordance with a preferred embodiment of the present invention, the searching step includes identifying, as a candidate EMT, an EMT which appears in a posting list of the index of a required query term, verifying the occurrences of all remaining required terms of the query in the content, the meta-data or ancestor content of the candidate EMT, verifying the absence of all forbidden terms of the query in the content, the meta-data and the ancestor content and advancing all posting lists of the index past invalid EMTs to select additional candidate EMTs.

Further, in accordance with a preferred embodiment of the present invention, the advancing step includes interpreting thread configuration data to determine the identities of the invalid EMTs.

Further, in accordance with a preferred embodiment of the present invention, the returning step includes choosing at least one qualifying EMT per qualifying EMT thread, which meets the query terms.

There is also provided, in accordance with a preferred embodiment of the present invention, a method including storing information describing configurations of discussion threads of EMTs, compacting the EMT discussion threads and indexing the compacted EMT discussion threads generated by the compacting.

DETAILED DESCRIPTION OF THE INVENTION

Applicants have realized that a significant portion of the volume of email messages in an email management system may be largely due to the repetition of messages in threaded discussions. Applicants have realized that similar threaded discussions are also common in newsgroups. The present invention may be operable for all systems which have threaded discussions.

Applicants have further realized that for well-ordered threads, the pattern in which messages are repeated is typical, as shown inFIG. 1. A well-ordered email discussion thread may be defined as one in which each email in the thread may contain the full content of its predecessor, i.e., the email preceding it in the thread, with no omissions or additions. Applicants have realized that the predictability of this repetition may be exploited when processing a volume of emails, so that portions of text that are repeated numerous times in successive emails, may be processed only once, rather than the multiple times they appear. This may result in a reduced volume of text to be processed.

Reference is now made toFIGS. 2,3and4in which exemplary, detailed versions of emails10,11and12comprising email exchange19introduced inFIG. 1are shown. As shown inFIG. 2, exemplary email10contains both text20, composed by the sender of email10to convey a message, and header30, which may list some or all of the meta-data M10associated with email10. Email meta-data is a record of information, logged by the email servers handling the email, regarding the sender, recipient, subject and chronology of the email. Email servers handling a volume of emails, such as the g-mail server administered by Google, may track the meta-data of all emails sent and received by the server. Email meta-data may include the names and email addresses of the email sender and the email recipient, the date and time the email was sent, and the subject of the email. This information may be stored in data fields ‘From’, ‘From-email’, ‘To’, ‘To-email’, ‘Date’ and ‘Subject’ respectively.

Electronic messages in general, of which email is one type, and of which newsgroup postings are another type, may have meta-data associated with each message transmission, as recorded by the server sending and receiving the messages.

Returning now toFIG. 2, meta-data M10indicates that on Wednesday, Oct. 6, 2004, at 5:29 PM, email10, regarding the bus schedule between San Francisco and Monterey, was sent by Bonnie Temple, from email address btemple@email.com, to the email address calitours@email.com. Header30lists some of the meta-data M10information as text in email10. The message conveyed by Bonnie Temple in content text20is an inquiry, for the purpose of an upcoming trip to California, about the bus schedule between the two subject California locations.

FIG. 3shows email11, which includes both reply text21and root message text20, as explained in the background. The new content of email11, i.e. reply text21, is a response to Bonnie from Nelly of Calitours Inc. providing the bus schedule information requested by Bonnie. The meta-data of email11, M11, indicates that on Wednesday, Oct. 6, 2004, at 7:06 PM, email11, regarding the bus schedule between San Francisco and Monterey, was sent by Calitours, from email address calitours@email.com to Bonnie Temple, at the address btemple@email.com. Meta-data M11may include a complete record regarding the sender, recipient, subject and chronology of email11, even though, as shown inFIG. 3, email11does not contain a header listing this information as in email10. It is also noted that the appearance of the term “Re:” in the Subject field indicates that email11refers to a previous message having the subject “Bus schedule between San Francisco and Monterey”.

FIG. 4shows email12which includes second reply text22in addition to first reply text21and root message text20. The content of reply text22sent by Bonnie to Nelly conveys her gratitude for the information provided by Nelly. Meta-data M12indicates that on Thursday, Oct. 7, 2004, at 11:35 AM, email12, regarding a previous message regarding the bus schedule between San Francisco and Monterey, was sent by Bonnie Temple, from email address btemple@email.com, to Calitours, at the email address calitours@email.com. Header32lists all of meta-data M12as text in email12.

As may be seen, in an email volume containing emails10,11and12, text20occurs three times, text21occurs two times, and text22occurs once. The present invention may be a search engine which may generally conserve email administration system resources by exploiting the structure of email threads to index each of text sections20,21and22one time only. The search engine may also search the index and rank search results according to retrieval policies based on the singularities of message thread structures, improving the effectiveness of the search and the quality of the results.

The search engine disclosed in the present invention may also be operable for all other types of electronic message transmission (EMT) volumes which are comprised of discussion threads, such as newsgroup postings.

A preferred embodiment of the present invention may be as shown inFIG. 5, to which reference is now made, and may employ search engine40to analyze, index and search a volume of EMTs50handled by EMT server48, which may include any number of EMT discussion threads (edt1. . . edtn). As shown inFIG. 5, search engine40may comprise a thread processor42, an indexer44, a thread management database43, an index58and a query manager46. Search engine40may support “free-text” search queries52regarding EMT volume50, and may provide search results54in accordance with retrieval policies based on the singularities of EMT thread structures. Free text queries include Boolean expressions on required and/or forbidden, regular and/or fielded, keywords and/or phrases. For example, a query on a volume of messages may dictate that a particular word or phrase appear in a message. Query criteria may also forbid the inclusion of a certain word or phrase. In the present invention, criteria may be set for the message itself or for the fields comprising the meta-data of the message.

Returning now toFIG. 5, the EMTs comprising EMT volume50may be grouped into threads edt1. . . edtnby EMT server48on the basis of the EMT meta-data logged by server48. Server48may also discern, within an EMT belonging to a thread, between new text appearing in the EMT for the first time in the thread, and repetitions of text from preceding messages, on the basis of the meta-data logged by server48for the EMTs in the thread.

Thread processor42may analyze threads edt1. . . edtnto ascertain their structures, assign identification numbers to each EMT, and compile thread structure reference tables, described in more detail hereinbelow, defining the structures of the EMT threads. Thread structure information processed by thread processor42may be stored in thread management database43. The output of thread processor42may be a compact EMT volume56, which may be smaller in size than original volume50. The reduced EMTs which form compact EMT volume56may consist of the new text contribution of each EMT in a thread and its meta-data, and may not include repetitions of text from preceding EMTs in the thread. Indexer44may create a traditional inverted index58for compact EMT volume56. Query manager46may process queries52input into search engine40by accessing thread management database43and index58. Query manager46may return search results54in response to query52.

EMT threads edt1. . . edtnmay have characteristic structural configurations, e.g. linear or conjoined. The exemplary email thread shown inFIG. 1is a linear thread. Each message in a linear thread contains the full text of all preceding messages in the thread.FIG. 6, to which reference is now made, shows an exemplary conjoined thread set.

As shown inFIG. 6, conjoined thread sets may occur when more than two people are involved in an electronic message discussion initiated by a single root message. In the example shown inFIG. 6, root email100is sent from John to Tom, but a copy is also sent to Sally. The copy sent to Sally precipitates a discussion between Sally and Tom which occurs in parallel with the discussion occurring between Tom and John, while the initial email from which both discussions evolved remains root email100. Another branch to the tree is added when Tom copies his reply to John (email102) to Mom, and Mom replies (email104) to Tom.

In a conjoined thread set configuration, such as that depicted inFIG. 6, discussions may split at any point, spinning off sub-threads. A conjoined thread set may be defined as a set of threads all sharing the same root message. Neither thread may be fully contained in the other, and beyond the common root message, the messages in the two threads may be disjoint. A set of conjoined threads may be seen as a directed tree, rooted at the root message. The tree-like structure of the conjoined thread set shown inFIG. 6is emphasized graphically inFIG. 7, reference to which is now made.FIG. 7shows that the exemplary conjoined thread set ofFIG. 6is rooted at root email100and has three branches concluding with emails101,103and104. The tree may be the union of the linear graphs defined by the individual threads in the conjoined set. A linear thread may therefore be seen as special and simple occurrence of a conjoined thread set.

Reference is now made toFIG. 8which shows the operation of thread processor42in detail. Thread processor42may comprise a docID assigner60, a root lookup table compiler62, a last offspring lookup table compiler64, a thread type determiner65and a compact EMT compiler66. Input50for thread processor42may be a collection of any number of EMT discussion threads (edt1. . . edtn), including linear threads (lt1. . . ltn) and conjoined thread sets (ct1. . . ctn). As shown inFIG. 8, the exemplary linear thread introduced inFIG. 1shall be referred to as thread lt1for the purposes of this discussion. Similarly, the exemplary conjoined thread set introduced inFIG. 6shall be referred to as thread ct1.

For linear EMT threads lt1. . . ltn, docID assigner60may assign consecutive numerical IDs (docIDs) to sequential EMTs on the basis of document creation time stored in the EMT meta-data. For conjoined thread sets ct1. . . ctn, DocID assigner60may use Depth First Search (DFS) numbering, as is well known in the art, on the directed tree implied by the thread-set, starting from the root document.

Root lookup table compiler62may analyze threads edt1. . . edtnand may compile a root lookup table67listing the root EMT docID for every assigned docID. Last offspring lookup table compiler64may analyze threads edt1. . . edtnand may compile a last offspring lookup table68listing the last offspring EMT docID for every assigned docID. The last offspring EMT of EMT X is defined as the EMT having the highest docID of all EMTs of which X is an ancestor. Taken together, root lookup table67and last offspring table68may effectively provide complete structural descriptions for all email threads edt1. . . edtn.

Thread type determiner65may then analyze the data in root lookup table67and last offspring lookup table68to determine whether a group of EMTs belonging to a thread edtiform a linear thread ltior a conjoined thread set cti. Thread type determiner65may compile this information in thread type lookup table69in which the value “L” (linear) or “J” (conjoined) may be assigned to each Root docID in root lookup table67. Thread type determiner65may identify that a root docID is the root of a linear thread if the root docID is common to a group of consecutive docIDs which also share a common Last Offspring docID. Thread type determiner65may identify that a root docID is the root of a conjoined thread set if the root docID is common to a group of consecutive docIDs which have differing Last Offspring docIDs.

It is noted that the thread type data may be joined, as shown by arrow61, to root lookup table67so that each docID in the system may be identifiable as belonging to a linear thread or to a conjoined thread set.

Compact EMT compiler66may compile compact EMT volume56by associating, with each assigned docID, the meta-data and the new text content associated with that docID.

Exemplary compact email volumes,70and72, for exemplary linear and conjoined email threads lt1and ct1respectively, are shown inFIG. 8. It may be seen that the compact emails constituting compact email volumes70and72may be comprised of the email meta-data and new content text associated with each email docID. For example, it is shown inFIG. 8that compact email10may comprise the meta-data associated with email10, indicated by the notation M10, and text20, the new text contribution in email10. The contents of compact emails11,12,100,101,102,103and104are similarly indicated inFIG. 8.

The reduction in volume realized by compact EMT compiler66may be seen by comparing the original volumes of email threads lt1and ct1and compact volumes70and72, respectively, represented graphically inFIG. 8. Compact email volumes70and72may comprise only one copy of each new message text portion, rather than the multiple repetitions of the text portions occurring in the non-compacted email threads.

Detailed representations of compact email volumes70and72are shown inFIGS. 9 and 10respectively, reference to which is now made. Compact email volume70for linear message thread lt1, as shown graphically inFIG. 8, and in detail inFIG. 9, may include the meta-data of emails10,11and12(M10, M11and M12), and only the new message content of each email, i.e. one copy of message text portions20,21and22, respectively. A significant reduction in indexed message volume may thus be achieved by the present invention, as the original volume of message thread lt1may include three copies of text portion20, two copies of text portion21and one copy of text portion22as shown inFIG. 8.

Similarly, compact email volume72for conjoined thread ct1,as shown graphically inFIG. 8, and in detail inFIG. 10, may include the meta-data of emails100-104, (M100, M101, M102, M103, and M104), and only the new message content of each email, i.e. one copy of message text portions90-94respectively. A significant reduction from the original volume of message thread ct1, which may include five copies of text portion90, three copies of text portion92and one copy each of text portions91,93and94, as shown inFIGS. 6 and 8, is thus realized.

Reference is now made toFIGS. 11aand11bwhich show the root and last offspring lookup data for email threads lt1and ct1respectively. Root lookup table74for linear thread lt1and root lookup table76for conjoined thread ct1are shown separately inFIGS. 11aand11brespectively for the sake of clarity, although as described inFIG. 8, all root lookup data for an entire email volume may be compiled in one table in a preferred embodiment of the present invention. Similarly, all last offspring lookup data for an email volume may be compiled in one table in a preferred embodiment of the present invention. For the sake of clarity however, the last offspring data for threads lt1and ct1are presented separately in tables75and77inFIGS. 11aand11brespectively.

A cursory review of these four tables may indicate how the structures of both linear and conjoined threads, and the distinction between them, may be completely described by the combination of root lookup table67and last offspring lookup table68. Out of a volume of random emails50, a thread may be distinguished as a group of emails having the same root email, such as emails10,11and12all sharing root email10as shown in table74ofFIG. 11a,and such as emails100-104all sharing root email100as shown in table76ofFIG. 11b.Accordingly, for a root lookup table having thousands of entries for an email server volume50, all docIDs sharing the same root may belong to one thread.

Last offspring lookup table68may provide the information necessary to distinguish linear threads from conjoined thread sets. A group of consecutively numbered emails which share their root email and their last offspring email is defined as a linear thread. As shown inFIG. 11a,email thread lt1meets this criteria, since all emails10-12in the thread share root email10and last offspring email12. As shown inFIG. 11b,email thread ct1does not meet this criteria. While emails100-104share root email100, there are three different last offspring docIDs among them. The last offspring of email101is email101, the last offspring of email103is email103, and the last offspring of emails100,102and104is email104. A group of consecutively numbered emails which have a common root email, but a variety of last offspring is defined as a conjoined thread set. Returning briefly toFIG. 7, where the three branches of conjoined thread ct1, correlating to last offspring emails101,103and104, are depicted graphically, it is shown that the number of unique last offspring docIDs for a conjoined thread set equals the number of branches in the thread.

Reference is now briefly made toFIG. 12which shows thread type lookup table73for exemplary email threads It1and ct1. In table73the root docID of each thread and its associated thread type are tabulated. The associated thread type for exemplary linear thread lt1whose root docID is 10, is shown to be “L” (linear), and the associated thread type for exemplary conjoined thread ct1whose root docID is 100, is shown to be “J” (conjoined).

As explained previously in the discussion ofFIG. 8, the thread type data in table73may alternatively be joined to root lookup table67. As shown inFIG. 12, table74′ shows root lookup table74ofFIG. 11aaugmented with thread type data. Table76′ similarly shows root lookup table76ofFIG. 11baugmented with thread type data.

Reference is now made toFIG. 13which shows the operation of indexer44in detail. Indexer44may generate an inverted index58for compact EMT volume56. The output of indexer44may comprise posting lists78for unique words (tokens) T1through Tiappearing in both the content and the meta-data of the compacted EMTs comprising compact EMT volume56. Each posting list78may store an ordered set of posting entries79where each entry may indicate the docID in which the token appeared, the specific location of the token within the meta-data or content, and whether the token appeared in the meta-data (“M”) or in the content (“C”) of the EMT. This information may be recorded as a triplet (docID, location, meta or content).

The value recorded in the second field indicating the location of the token in the docID may refer to a word count position in the meta-data of the EMT if the value in the third field is an “M”, or to a word count position in the content of the EMT if the value in the third field is a “C”.

Reference is now made toFIGS. 14 and 15which show exemplary posting lists78for compact email volumes70and72shown inFIGS. 9 and 10for exemplary email threads It1and ct1respectively. InFIG. 14, posting list80shows posting entries for the token “Monterey”. Posting list81shows posting entries for the token “December”, posting list82for the token “you”, and posting list83for the token “btemple@email.com” appearing in the From-email field of the email meta-data. The three values (10,25, C) recorded in exemplary posting entry88, indicate that the token ‘Monterey’ appears in docID number10, in word position number25of the message content as can be seen inFIG. 9. The three values (12,3, M) recorded in exemplary posting entry89, indicate that the token ‘<btemple@email.com>’ appears in word position number3after the colon sign following the ‘From:’ field in the meta-data of docID number12as can also be seen inFIG. 9.

InFIG. 15, exemplary posting lists85,86and87list posting entries for the tokens “Tom”, “John” and “Mom”, respectively, as they appear in compact email volume72ofFIG. 10.

Reference is now made toFIG. 16which describes the operation of query manager46in detail. Query manager46may utilize the information about the thread structures stored in thread management database43to process user-input queries52regarding EMT volume50in a generally more time and resource efficient manner than if volume50were searched as an assortment of random unrelated text. The information about the EMT thread structures stored in thread management database43may organize EMT volume50into its component threads, and query manager46may navigate among these threads using the thread structure information as a map as discussed in further detail inFIGS. 17 and 18. Owing to the map provided by the thread structure information, query manager46may conduct selective searches of EMT volume50. For example, in the present invention, query manager46may anticipate that a forbidden term found in a root email may appear in all subsequent emails in the thread and thus, the subsequent emails may all be disqualified immediately without being searched. Query manager46may anticipate these and other particularities of threaded EMT discussions, and may exploit them to optimize the efficiency of the searching, scoring and ranking processes.

Query manager46may accomplish the task of guided systematic and selective searching of EMT volume50, by beginning at a certain start point, i.e., by selecting one message candidate, and then, in an iterative process, using the rules and conditions prescribed in the algorithms disclosed hereinbelow to validate or disqualify that candidate, and to determine the next candidate to be checked. Query manager46may conserve system resources by skipping around message volume50to select candidates as dictated by the thread-savvy algorithms.

In accordance with a preferred embodiment of the present invention, query manager46may conduct a selective, time and resource efficient search of a message volume50as described above without any loss of recall, that is, without failing to retrieve qualifying results to a query due to the shortcuts taken in the indexing and search processes.

Returning now toFIG. 16, query52may consist of required terms R1. . . Rn, forbidden terms F1. . . Fnand optional terms O1. . . On. Generally speaking, an email may not be a qualifying result in response to query52if it does not contain appearances of required terms R1. . . Rn. An email may also not be a qualifying result in response to query52if it contains an appearance of any forbidden term F1. . . Fn. An email not disqualified for containing forbidden terms and containing any of optional terms O1. . . Onmay be more likely to be returned as a result response to query52than an email not containing any of optional terms O1. . . On.

As shown inFIG. 16query manager46may comprise a postings iteration manager (PIM)120, a candidate enumerator (CE)122, a candidate scorer124and a candidate ranker126.

Candidate enumerator122may employ postings iteration manager120in an iterative process in which, at any given time, one docID, the CandidateMessage, may be under consideration for qualifying as a search result for query52. Postings iteration manager120may traverse posting lists PL1. . . PLnof required terms R1. . . Rn,optional terms O1. . . Onand forbidden terms F1. . . Fnof query52. Candidate enumerator122may maintain three message pointers-CandidateMessage, CandidateRoot, and LastOffspring. The pointer CandidateMessage may point to the document ID docIDiunder consideration for candidacy as a response to query52at any given time. The pointer CandidateRoot may point to the root docID of docIDi, and the pointer Last Offspring may point to the last offspring docID of docIDi. The iterative process of candidate enumeration and examination for qualification performed by CE122and PIM120is discussed in greater detail with respect toFIGS. 17 and 18.

A message meeting the search criteria, i.e. a qualifying candidate QCi, may proceed to candidate scorer124for scoring. Qualifying candidates QC1. . . QCnand their associated scores, ScQC1. . . ScQCnmay proceed to candidate ranker126for ranking.

Candidate scorer124may assign scores to qualifying candidates QC1. . . QCn, with ‘better’ candidates receiving higher scores. For example, a candidate email containing a certain number of optional terms O1. . . Onmay be assigned a higher score than a candidate email containing a lesser number of optional terms O1. . . On. Candidate ranker126may assess the candidate scores on the basis of the retrieval policies of search engine40, and may assess which qualifying candidates may be returned by the search engine as results to query52. The retrieval policies of search engine40may be system or user defined.

Reference is now made toFIGS. 17 and 18, which describe the iterative process of candidate enumeration and verification performed by CE122and PIM120.FIG. 17provides an example for the initial steps of the process.FIG. 18is a flowchart which describes a complete cycle of the process from nomination through validation of a candidate message.

In the example shown inFIG. 17, query52may contain required terms R1, R2and R3. Postings iterator PIR1may traverse the posting list for term R1(PLR1), postings iterator PIR2may traverse the posting list for term R2(PLR2) and postings iterator PIR3may traverse the posting list for term R3(PLR3). In the first step of the process (step G1inFIG. 18), posting iterator PIR1may select the first occurrence OCR1of required term R1. In the example shown inFIG. 17, OCR1is located at posting entry (PE)152. Upon the selection of occurrence OCR1by postings iterator PIR1, candidate enumerator122may enumerate docID115for candidacy and pointer CandidateMessage may point to docID115(step G2inFIG. 18).

Candidate enumerator122may then access root lookup table67to determine the root of the candidate message (step G3inFIG. 18). In the example shown inFIG. 17, the root of the candidate message docID115, is 100 according to root lookup table67as, in the example ofFIG. 17, all docIDs numbered100to199in root lookup table67have root100, all docIDs numbered200to299have root200, etc. Pointer CandidateRoot may then point to the root of the candidate message, e.g. docID100in the example ofFIG. 17.

In a preferred embodiment of the present invention, candidate enumerator122may consult root lookup table67to ascertain whether the candidate message is part of a linear or conjoined thread (step G4inFIG. 18). In this embodiment, one process is provided for candidate messages belonging to linear threads (steps L1through L6inFIG. 18) and a different process is provided for candidate messages belonging to conjoined thread sets (steps J1through J7inFIG. 18) In another preferred embodiment of the present invention, all candidate messages may be processed as conjoined thread sets. The conjoined thread set procedure may be valid for both conjoined thread sets and linear threads since a linear thread is a simple, special instance of a conjoined thread set.

As shown inFIG. 18, candidate enumerator122may determine that a candidate message belongs to a linear thread (step L1), and begin the procedure for checking a candidate message which belongs to a linear thread (step L2). Candidate enumerator122may then check if either one of the following two conditions are true for an occurrence of each of the remaining required terms, R2. . . Rnon posting lists PLR2. . . PLRnrespectively, as located by PIR2. . . PIRnrespectively.

The two conditions may be:La) The occurrence of the required term is a meta occurrence in docID [CandidateMessage]; andLb) The occurrence of the required term is a content occurrence in a docID in the range of {CandidateRoot . . . CandidateMessage}.

These conditions imply that when the postings iterator of a posting list of a required term PIRiis on a message with docID X, all other posting lists may be safely advanced to a position at or beyond Root [X] without any loss of recall.

Returning to the example shown inFIG. 17, CE122and PIM120may check CandidateMessage115and CandidateRoot100against conditions La and Lb. To this end, CE122may examine the occurrence of required term R2at posting entry154on PLR2. Posting entry154indicates a content occurrence of required term R2in docID100. Candidate enumerator122may ascertain that occurrence154meets condition Lb above since the occurrence of term R2at docID100is a content occurrence of the required term in the range of {Root [X] . . . X}, that is, in the range {100 . . . 115}.

Candidate enumerator122may then consider occurrence156, of required term R3in docID105, as located by postings iterator PIR3. However, since occurrence156is a meta-occurrence, it must fulfill condition La, and since the candidate message under consideration is docID115and not docID105, condition La is not satisfied. Condition Lb is also not satisfied by occurrence156because condition Lb requires a content occurrence and not a meta occurrence. Postings iterator PIR3may then advance to occurrence158of term R3on PLR3. This occurrence is found to satisfy condition Lb because it is a content occurrence at docID105falling in the required range of 100 to 115.

Returning now toFIG. 18, candidate enumerator122may proceed to step L3if it determines that every required term of query52meets one of conditions La or Lb. Candidate enumerator122may proceed to step L4and choose a new candidate message if at least one required term of query52does not meet condition La or Lb.

During step L3, CE122may determine if the candidate message under consideration is limited to CandidateMessage, or if all docIDs in the range {CandidateMessage . . . LastOffspring[CMsg]} may also be candidates. The last offspring of the candidate message, LastOffspring[CMsg] may be determined by CE122either by accessing last offspring lookup table68, or by finding the highest docID in root lookup table67which has the same root as CandidateMessage. Referring briefly toFIG. 17, it may be seen in last offspring lookup table68that the last offspring of CandidateMessage115is docID199, and that the highest docID in root lookup table67sharing root100with CandidateMessage115is docID199.

Returning now toFIG. 18, CE122may consider all docIDs in the range {CandidateMessage . . . LastOffspring[CMsg]} if condition Lb in step L2applies to all required terms posting lists (i.e., a match with no meta-occurrences has been identified). In this case, it may be guaranteed that all messages in the thread whose docID is greater than CandidateMessage may also be qualifying messages, due to the structural nature of well-ordered threaded EMTs, dictating that an EMT X in a thread, by definition, contains all of the content of the EMTs preceding it in the thread.

CE122may then proceed to verify (step L5) the absence of forbidden terms in CandidateMessage or in the range {CandidateMessage . . . LastOffspring[CMsg]}. CE122may examine the occurrences of all forbidden terms F1. . . Fnwhich fall within the range [CandidateRoot, . . . CandidateMessage] to determine if CandidateMessage or ranges of messages in the thread to which CandidateMessage belongs may be disqualified for containing forbidden terms. Candidate enumerator122may disqualify candidate messages according to the following rules:LaF) A ‘content’ type occurrence of any forbidden term F1. . . Fnanywhere in range [CandidateRoot, . . . CandidateMessage] may disqualify all the messages in the thread whose docID is greater than or equal to CandidateMessage; andLbF) A ‘meta’ type occurrence within CandidateMessage may disqualify only CandidateMessage.

Candidate enumerator122may proceed to step LA and choose a new candidate message if all candidate messages are disqualified in step L5for containing forbidden terms. Qualifying candidate messages not disqualified for containing forbidden terms may proceed to candidate scorer124(step G5).

Candidate scorer124may assign scores to qualifying candidates on the basis of all the occurrences of query terms R1. . . Rnand O1. . . Onin the message by iterating through query term occurrences in the range [CandidateRoot, . . . CandidateMessage] of all term posting lists. All content occurrences in the range may contribute to the score of a qualifying candidate QC, but meta occurrences may only contribute to the score of a qualifying candidate if they occur in the qualifying candidate itself.

Once candidate enumerator122verifies a qualifying candidate or candidates, CE122may proceed to step L6. In step L6, candidate enumerator122may choose the next candidate message in consideration of the retrieval policy of search engine40. For example, the retrieval policy of search engine40may dictate that it is sufficient to return as search results, only the first message in each thread which satisfies query52. In this case, after scoring one qualifying candidate, candidate enumerator may start searching for the next candidate beginning from the next thread, i.e., candidate enumerator122may skip all messages in the thread of the current qualifying candidate.

Alternatively, if the retrieval policy of search engine40dictates that all relevant messages in the thread should be returned as search results, the search may be continued from CandidateMessage+1. This method may allow search engine40to easily identify the highest scoring message of the thread—all thread candidates may be enumerated sequentially, since they may be indexed with consecutive docIDs. Furthermore, scores for successive docIDs in a thread may be computed simply by candidate scorer124on the basis of the scores of preceding docIDs, that is, according to a methodology based on the patterns of the email thread, in the following way: It is assumed that the score S(k) of message k was just computed by candidate scorer124, and that the next CandidateMessage may be k+j. Since the content of each message may be fully contained in the text of the following messages, the score S(k+j) of message (k+j) may equal to:
S(k+j)=S(k)+CS(k+1, . . . ,k+j)−MS(k)+MS(k+j)

where CS indicates the score contributed by content occurrences and MS indicates the score contributed by meta occurrences.

Returning now to step G4inFIG. 18, candidate enumerator122may determine (step J1) that a candidate message belongs to a conjoined thread set, and then begin the examination procedure. Candidate enumerator122may first access last offspring lookup table68to determine (step J2) the last offspring of the candidate message. Then CE122may proceed to step J3and begin the verification process of the candidate message, in which CE122may determine if either one of the following two conditions are true for at least one occurrence of each of the remaining required terms, R2. . . Rnon posting lists PLR2. . . PLRnrespectively, as located by PIR2. . . PIRnrespectively.

The two conditions may be:Ja) The occurrence of the required term is a meta-occurrence in docID [CandidateMessage].Jb) The occurrence of the required term is a content occurrence in docID X where X≦CandidateMessage and LastOffspring [X]≧CandidateMessage.

These conditions imply that when the postings iterator PIRiof a posting list PLRiof a required term Riis on a message with docID k, all other posting lists may be safely advanced to a position satisfying the following two conditions without any loss of recall:I. at or beyond Root [k] but no later than k; andII. the LastOffspring of the position to which the posting list is advanced is not smaller than k.
When condition (I) holds, but condition (II) does not, (i.e., a query term is in a position X greater than Root[k] but LastOffspring[X}<k), the posting list of the term may be safely advanced to a position beyond LastOffspring [X].

CE122may then proceed to step J4if it determines that every required term of query52meets one of conditions Ja or Jb. CE122may proceed to step J5and choose a new candidate message if at least one required term of query52does not meet condition Ja or Jb.

During step J4, CE122may determine if the candidate message under consideration is limited to CandidateMessage, or if all docIDs in the range {CandidateMessage . . . LastOffspring[CMsg]} may also be candidates. CE122may consider all docIDs in this range if condition Jb in step J4applies to all posting lists (i.e., a match with no meta-occurrences has been identified). In this case it may be guaranteed that all messages in the thread whose docID is no larger than LastOffspring [CandidateMessage] may also be candidates.

CE122may also use the following rule to improve searching efficiency: If an occurrence of a query term in docID X satisfies CandidateRoot<X<CandidateMessage but LastOffspring[X]<CandidateMessage, the posting list of the term may be advanced to the docID numbered LastOffspring[X]+1.

Candidate enumerator122may then proceed (step J6) to verify the absence of forbidden terms in CandidateMessage or in the range {CandidateMessage . . . LastOffspring[CMsg]}. CE122may examine the occurrences of all forbidden terms F1. . . Fnthat fall within the range [CandidateRoot, . . . CandidateMessage] to determine if CandidateMessage or ranges of messages in the thread to which CandidateMessage belongs may be disqualified for containing forbidden terms. Candidate enumerator122may disqualify messages according to the following rules:JaF) A ‘content’ type occurrence of any forbidden term F1. . . Fnat location X satisfying X≦CandidateMessage and LastOffspring [X]≧CandidateMessage, may disqualify X and all its offspring, i.e. all messages whose docID is between X and LastOffspring [X] (inclusive).JbF) A ‘meta’ type occurrence within CandidateMessage may disqualify only CandidateMessage.

CE enumerator122may proceed to step J5and choose a new candidate message if all candidate messages are disqualified in step J6for containing forbidden terms. Qualifying candidate messages not disqualified for containing forbidden terms may proceed to candidate scorer124(step G5).

Candidate score assessor124may assign scores to qualifying candidates on the basis of all the occurrences of query terms R1. . . Rnand O1. . . Onin the message by iterating through query term occurrences in the range [CandidateRoot, . . . CandidateMessage], of all term posting lists. All content occurrences in docIDs whose LastOffspring≧Candidate Message may contribute to the score of the qualifying candidate, but meta occurrences may only contribute to the score of the qualifying candidate if they occur in the qualifying candidate itself.

Once candidate enumerator122verifies a qualifying candidate or candidates, CE122may proceed to step J7. In step J7, candidate enumerator122may choose the next candidate message in consideration of the retrieval policy of search engine40. For example, the retrieval policy of search engine40may dictate that it is sufficient to return as search results, only the first message in each thread which satisfies query52. In this case, after scoring one qualifying candidate, candidate enumerator may start searching for the next candidate beginning from the next thread, i.e., candidate enumerator122may skip all messages in the thread of the current qualifying candidate, and begin searching at the docID numbered LastOffspring[CandidateRoot]+1.

Alternatively, if the retrieval policy of search engine40dictates that all relevant messages in the thread should be returned as search results, the search may be continued from CandidateMessage+1. This method may allow search engine40to easily identify the highest scoring message of the thread set—all thread candidates may be enumerated sequentially, since they may be indexed with consecutive docIDs. For scoring, operations may depend on whether CandidateMessage+1 refers to CandidateMessage, (i.e., CandidateMessage is an ancestor of CandidateMessage+1). If CandidateMessage+1 refers to CandidateMessage, scores for successive docIDs may be computed simply by candidate scorer124as described previously for linear threads.

However, if the last scored CandidateMessage has no offspring, the CandidateMessage counter may be advanced by one, and all posting lists may be set to the root of the new CandidateMessage, in which case some posting lists may be rewound.

Alternatively, search engine40may follow a hybrid approach and may return one message per qualifying thread in the thread set. This may be achieved by advancing the next candidate to LastOffspring[CandidateMessage]+1.

In an additional preferred embodiment of the present invention, illustrated inFIG. 19, reference to which is now made, the thread-based candidate enumeration process performed jointly by candidate enumerator122and postings iteration manager120in an iterative process as described hereinabove, may be separated from the other query manager processes and may be performed by virtual cursor layer130as shown inFIG. 19. This embodiment may allow thread-aware searches to be conducted within query processors which have not been especially adapted to this particular type of search method, such as query processor135shown inFIG. 19.

Objects and processes illustrated inFIG. 19which are analogous to objects and processes illustrated inFIG. 16are identified with corresponding reference numerals. In both embodiments of the present invention, as shown inFIGS. 16 and 19, query52may comprise the input for query manager46. In both embodiments, postings iteration manager120may employ posting iterators, also known in the art as physical index cursors, for each query term as shown inFIG. 17. However, while postings iteration manager120and candidate enumerator122may work in tandem, as shown inFIG. 16and as described hereinabove, to perform the process of candidate enumeration,FIG. 19shows how virtual cursor layer130, in accordance with an additional preferred embodiment of the present invention, may serve as an intermediary between postings iteration manager120and thread management database43, directing selection of candidate EMTs by the posting iterators within postings iteration manager120. Postings iteration manager may thus be contained within a query processor135, as shown inFIG. 19, which may be separate from virtual cursor layer130, and which may not be specially adapted to conduct thread-aware query processing.

Virtual cursor layer130may operate as if it were superimposed over the posting iterators within postings iteration manager120. Virtual cursor layer130may thus provide knowledge of the thread structure of the EMT volume being queried, as described by the data stored in thread management database43, which may include root lookup table67and last offspring table68(FIG. 16), to the underlying posting iterators. The candidate enumeration process conducted by the posting iterators may thus, as in the embodiment of the present invention illustrated inFIG. 16, be steered according to the peculiarities of the EMT volume thread structure.

The employment of virtual cursor layer130may isolate the query process from the EMT volume thread structure model, and may thus allow the EMT volume thread structure model to be used in a query process while the query process may remain oblivious to the details of the thread structure and its implementation in candidate enumeration. This embodiment of the present invention may thereby allow thread-aware searches to be conducted within query processes which have not been specially adapted to this particular type of search method.

Virtual cursor layer130may be provided by creating a “positive” virtual cursor for each required term, and a “negative” virtual cursor for each forbidden term in query52. Algorithms may be provided for the positive and negative versions of two basic cursor methods next( ) and fwdBeyond( ), as well as for the method fwdShare( ). These algorithms, PositiveVirtual::next ( ), PositiveVirtual::fwdBeyond ( ), NegativeVirtual::next ( ), NegativeVirtual::fwdBeyond ( ) and Physical::fwdShare ( ) may dictate the movements of the virtual cursors and the underlying posting iterators, thereby enumerating candidate EMTs. Pseudocode for the algorithms is shown inFIG. 20, reference to which is now made.

Algorithms140,142,144,146and148shown inFIG. 20describe a candidate enumeration procedure which is similar in principle to the procedure explained hereinabove with respect toFIGS. 16 and 17. Both candidate enumeration procedures utilize the EMT thread structure description data to dictate the movement of the posting iterators so that the query process may be conducted in a more efficient manner than would be possible without the data, as explained hereinabove with respect toFIGS. 16 and 17.

In the algorithms shown inFIG. 20, THIS.DOCID corresponds to the current position of the virtual cursor, and the term CPcorresponds to the underlying physical cursor. Algorithm140, for positive next( ), forwards the virtual cursor for term Ti to the next docID that contains term Ti. When CPis on a shared posting, all of the offspring of CP, which inherit term Ti from CP, are enumerated, as shown in lines2-4of the pseudocode, before CPis physically moved, in line7of the pseudocode.

Algorithm142, for positive fwdBeyond(d), as shown inFIG. 20, forwards the virtual cursor to the next docID at or beyond docID D which contains term Ti. This algorithm may rely on the physical cursor method fwdshare( ) to do most of its work. The call to CP.fwdShare(d), in line6of algorithm142, attempts to position CP on the next document that shares term Ti with docID D. If there is no such document, fwdshare( ) returns with CP positioned on the first document beyond d.

Algorithm144, for negative next( ), as shown inFIG. 20forwards the virtual cursor to the next document not containing term Ti. It works by striving to keep CP positioned ahead of the virtual cursor. The documents d ε {THIS.DOCID, . . . CP−1}, which do not contain the term, may be enumerated until the virtual cursor catches up to CP, as shown in line4of the algorithm. When that happens, the virtual cursor is forwarded past the offspring of CP, which inherit the term from CP, as shown in lines5-9of algorithm144, after which CP is moved forward, as shown in line10. These steps may be repeated until CP moves ahead of the virtual cursor again.

Algorithm146, for negative fwdBeyond(d) forwards the virtual cursor to the next docID at or beyond docID D that does not contain the term Ti. As shown in line6of algorithm146fwdShare(d) is called to position CP on the next docID which shares term Ti with docID D. Then, as shown in line14, next( ) is called to position the virtual cursor on the next document that does not contain term Ti.

Algorithm148, for fwdShare(d) strives to forward the physical cursor so that it shares term Ti with docID D. If there is no such document, it returns with the cursor positioned on the first docID beyond D. This is accomplished, as shown in line1of algorithm148, by looping until the physical cursor moves beyond D or to a posting that shares term Ti with docID D. The movement of the physical cursor depends on where the cursor lies. As shown inFIG. 20, lines5-7of algorithm148pertain to the scenario in which the cursor lies outside of the entire conjoined thread set to which docID D belongs. Lines9-11of algorithm148pertain to the scenario in which the cursor lies within the conjoined thread set to which docID D belongs but not within the linear thread to which docID D belongs. Lines13-15.of algorithm148pertain to the scenario in which the cursor lies on a private posting, that is, a particular occurrence of Ti which is not shared by any other docID. For example, all meta-occurrences are private, as well as occurrences in a solitary EMT which is its own root and last offspring.

In the additional preferred embodiment of the present invention illustrated inFIG. 19, candidate scoring and ranking may proceed as described inFIG. 16.