Information Retrieval from Annotated Texts with Applications to Hypertexts Aviezri S. Fraenkel Dept. of Applied Math. & CS The Weizmann Institute of Science Rehovot 76100, Israel Shmuel T. Klein Dept. of Math. & CS Bar Ilan University Ramat-Gan 52900, Israel August 23, 1995 Abstract Methods for the correct and efficient handling of annotations in a full-text retrieval system are investigated, with applications to a Hypertext environment in which even the hyperlinks are considered as searchable annotations. The problem with annotations is that they cannot be treated as regular text, since this would disrupt proximity searches, but on the other hand, they cannot be ignored, as they may carry important information. Moreover, in some cases, a user may wish to restrict a search to prespecified subsets of annotations. We suggest a new way of indexing the terms of the database to overcome the above dilemma. Keywords: Full-text information retrieval systems, annotations, inverted files, hypertext, hyperlinks. 1. Introduction and Background We consider a full text retrieval system based on a large data textual corpus written in some natural language. The special case investigated here does not restrict the text to consist of a linear sequence of words, but allows for what we shall call below layers of annotations: each annotation is an additional text block of varying size (from a few words to several pages), attached to a main text portion either by the author or by an independent editor, generally to elucidate some point in the main text. These annotations may consist of: ffl short references to other texts, or to other passages in the same text, which are often included in the main text and labeled as an annotation either by special font or typesize or some form of brackets, e.g., cf. Hamlet, Scene II or see above, page 15 ; ffl various types of footnotes; these tend to be short in general, but depending on the type of literature, their total amount may sometimes even exceed that of the original text, e.g., in many law related publications; - 1 - ffl commentaries to classical or widely accepted texts, such as Bible commentaries or annotations to Alice in Wonderland . Note that with each word of the main text, several different annotations1 \Lambda may be \Lambda or comments added in the margins by persons claiming that the margins are too small to accommodate their proofs associated. Our work has applications to a Hypertext environment [6], in which the database consists of a large collection of texts that frequently refer to each other by means of a set of hyperlinks. On the one hand, our approach is different from the usual Hypertext approach [1, 4], in that we consider a main text, and look upon the annotations as having a somewhat different status, whereas the texts linked together in a Hypertext system are judged to be on the same level. On the other hand, we consider the hyperlinks themselves to be annotations, which turns them into searchable text, contrary to the usual Hypertext approach. To give an example, suppose that we look for mathematical papers on surgery (in topology, manifold structures, differential geometry, homotopy, etc.). On March 17, 1995, we ran the search surgery on the WWW using the WebCrawler search engine at URL: http://webcrawler.cs.washington.edu/WebQuery.html which returned 374 WWW sites. As we might imagine, the bulk of them was on clinical surgery. Buried among them was John Roe's Home Page at URL: http://www.jesus.ox.ac.uk:80/~jroe/ with information on a graduate course entitled Surgery for amateurs (and its links with coarse geometry and the classification of manifold structures). Though this was not exactly what we were looking for, it was a good lead to papers on this topic. If the WWW would have searchable links, we could have constrained the search by the condition that surgery and (a link containing the word math or a link to Mathematical Reviews) appear at a distance of no more than one sentence apart. Such links do not appear in the text, only in the html background language. Presumably, such a modified search would lead us immediately to abstracts of papers on the requested subject, with much improved recall 2 and precision3. It is true that a search for surgery AND math returned only 43 WWW sites. But also here the bulk was about mathematicians employed in departments of surgery; schools of medicine with mathematics departments; and universities having both schools of medicine and mathematics. (The search engines on the WWW do not use metrical operators other than "document", to the best of our knowledge.) The main problem caused by the presence of annotations is that they disrupt the flow of the main text. The designer of an IR system is then faced with the following dilemma. He cannot just ignore the annotations, since they may be a legitimate way chosen by the author to convey information, or, in the case the annotation has been added by somebody 1such as various comments written as footnotes : : : 2defined as the fraction of the relevant items that have been retrieved 3the fraction of the retrieved items that are relevant - 2 - else, they may often add clarity or help the reader in some other way. But treating the annotations as regular text may confound proximity searches, as in the following example: : : : one of the well-known tautologies (2b . : (2b)) is due to Shakespeare : : : with the part in parentheses being an annotation; a search for Shakespeare and tautologies within a distance of up to five words would fail, even though the main text would qualify for it. In the next section, the problem is formally defined. In Section 3, we suggest some ways to deal with the problem and discuss solutions and their implementation details. 2. Formal Statement of the Problem The question of how to treat annotations may be asked independently from the method used to implement the search engine of the information retrieval system. The suggested solutions will, however, depend on these implementation details. The simplest approach, and the one mostly used for small databases, is to retrieve the requested information by means of a sequential search through the text. We thus require here that the beginnings and endings of annotations should be clearly marked by some control sequence. But such direct searches are not feasible for larger databases. We therefore focus below on one of the alternative methods. Nevertheless, the solutions suggested below are applicable, in principle, to sequential search, as long as the database structure permits to count the serial number of every word in every sentence, and the serial number of every sentence in every document or every paragraph. The usual approach to full-text retrieval is to use inverted files, that is, auxiliary files such as a dictionary and a concordance [7]. As used here, a dictionary is an easily searchable list of all the different words occurring in the text and usually contains for each word some statistical information such as the total number of times it occurs and the number of documents in which it appears, as well as a pointer into the concordance. A concordance contains for every word, W , the complete list of locations in the text where W appears. Depending on the underlying hierarchical structure of the text, these references may take various forms, for example, each reference could be represented by the 5-tuple (a; d; p; s; w), called a coordinate, where a is the author(s), d is the document number, p is the paragraph number (in the document), s is the sentence number (in the paragraph) and w is the word number (in the sentence); or, alternatively, a coordinate could consist of book number, page, line; or simply, when any other structure is lacking, the number of the physical block containing W and the offset within the block. The order of the coordinates in the concordance is induced by the order of the terms in the dictionary. Internally, for a given word, its references are lexicographically ordered according to the fields of the coordinate. Depending on the database, values in the field corresponding to the highest level (the level of authors in the first mentioned hierarchy above) are generally listed in chronological order. The retrieval process then consists of accessing the concordance for each keyword and collating the corresponding lists of coordinates. - 3 - More formally, a query consists of an optional level-indicator, m keywords and m \Gamma 1 binary distance constraints, as in level : A1 (l1; u1) A2 (l2; u2) \Delta \Delta \Delta Am\Gamma 1 (lm\Gamma 1; um\Gamma 1) Am: (1) This is a conjunctive query, requiring all the keywords Ai to occur within the given metrical constraints specified by li, ui, which are (positive or negative) integers satisfying li ^ ui for 1 ^ i ! m, with the couple (li; ui) imposing a lower and upper limit on the distance from Ai to Ai+1. Negative distance means that Ai+1 may appear before Ai in the text. The distance is measured in words (the default value), sentences or paragraphs, as prescribed by the level-indicator. In a more general setting, one could also consider extended queries, consisting of several disjuncts, each having a form similar to (1). The requested set of locations to be retrieved is then simply the union of the sets of locations to be retrieved for each of the disjuncts. We may therefore restrict our attention to queries of the form (1). In its simplest form, the keyword Ai is a single word or a (usually very small) set of words given explicitly by the user. In more complex cases a keyword Ai will represent a set of words Ai = Snij=1 Aij, all of which are considered synonymous in the context of the given query. For example, a variable-length-don't-care-character \Lambda can be used, which stands for an arbitrary, possibly empty, string. This allows the use of prefix, suffix and infix truncation in the query. Thus Ai could be comput\Lambda , representing, among others, the words computer, computing, computerize, etc.; or it could be \Lambda mycin, which retrieves a large class of antibiotics; infix truncation also can be useful for spelling foreign names, such as Ba\Lambda tyar, where \Lambda could be matched by h, k, kh, ch, sh, sch, etc. Another possibility for getting the variants of a keyword is from the use of a thesaurus (month representing January, February, etc.), or from some morphological processing (do representing does, did, done, etc.). For every word W , let C(W ) be the ordered list of the coordinates of all its occurrences in the text. The problem of processing a query (1) consists then, in its most general form, of finding all the m-tuples (a1; : : : ; am) of coordinates satisfying 8i 2 f1; : : : ; mg 9j 2 f1; : : : ; nig with ai 2 C(Aij) and li ^ d(ai; ai+1) ^ ui for 1 ^ i ! m; where d(x; y) denotes the distance from x to y on the given level. Every m-tuple satisfying these constraints is called a solution [2]. In the presence of annotations, there are three main possibilities: 1. Treat annotations as non-retrievable text . This is the easiest solution from the point of view of the overhead, and this is the standard way of treating the links in Hypertext. Of course, important information may be lost, so that recall and/or precision are often reduced. On the other hand, the annotations are only ignored for retrieval purposes, that is, they are not pointed to from the concordance, but will not be discarded on presentation if they happen to appear in proximity of text to be displayed. - 4 - 2. Embed annotations into the regular text . This is the easiest solution from the point of view of the processing, and it is the standard way of treating short remarks in parentheses. This may cause retrieval errors, due to the disruption of the main text, and may thus lower both recall and precision. 3. Treat annotations as special text . This is the approach advocated in this paper, though it is more expensive both in terms of additional storage and of processing time. It permits to include or exclude, for any search, prespecified subfamilies of annotations -- which is not possible in the previous two alternatives. We are thus looking for data structures and methods that will permit standard full-text retrieval as explained above, regardless of the presence or absence of annotations in the text. In particular: proximity searches should be processed correctly, i.e., the numbering of the words, sentences and paragraphs of the main text should not be altered, even if an annotation appears close to the required keywords; the search for solutions to a given query should, however, also include the text of any prespecified subset of annotations, possibly excluding the main text itself; finally, annotations should be considered as alternative, yet legitimate, extensions of the main text, so that under conditions specified below, text portions should be retrieved even if one keyword appears in the main text, and another keyword appears in the annotation, within the required range. 3. Methods of embedding annotations The algorithmic solutions to the first two possibilities above are straightforward. If annotations are considered non-retrievable, they are just ignored when inverting the files. If they are embedded in the regular text, their coordinates appear in the concordance just as do those of the main text. The problem with the third possibility, discussed below, is that for each coordinate, additional information must be kept to indicate if the corresponding term belongs to an annotation or not. 3.1 Theoretical aspects Let us first investigate how the coordinates should be numbered. Consider, for example, the sentence a1 a2 a3 b1 b2 b3 b4 a4 a5 a6; where ai are considered words of the main text, and bi words in annotations. Since the presence of the annotation should not disrupt the numbering of the words in the main text, the internal number (within the sentence) of ai should be i. But the word b1 is, in a certain sense, also the fourth word in the sentence. It is thus not enough to have a separate numbering for annotation words; rather, their coordinates must somehow refer to the word in the main text to which they are annotated. A possible solution is to define the internal numbering of coordinates of annotating words as continuing the sequence of the numbering of the main text, which, for the above example, would mean that the internal numbering of the words bi should be i + 3. Therefore, some indicator flag is - 5 - needed to differentiate between terms with identical internal number. The question of semantic and metrical relationships between b4 and a4 will be discussed below. A one-bit flag would be too restrictive in this case. First, there might be more than one kind of annotation, e.g., comments written by various editors, and several annotations may well apply to a single location in the main text, as in a1 a2 a3 b1 b2 c1 c2 a4 a5 a6: (2) Here, b1, c1 and a4 should all have index 4. This could still be dealt with by considering the union of all the annotations to the same point in the main text as constituting a single annotation. But this would be against our philosophy of letting the user decide which kinds of annotations he wants to search, and which he wishes to disregard. Secondly, even if all the annotations are of the same kind and point to different locations, they might be long enough to have the numbering of their words overlap. Consider, for example, the following sentence: a1 a2 a3 b1 : : : b17 a4 a5 : : : a10 c1 : : : c10 a11 a12 : : : ; where bi and ci are annotation words. In this example, the indices of the words b7+j, cj and a10+j would all be identical to 10 + j, for 1 ^ j ^ 10, so a one-bit flag would not suffice to resolve this ambiguity. A possible solution would thus be to define an extended coordinate, including also a tag field indicating whether the coordinate points to a word in the main text or to an annotation, and in the latter case, giving also information about the type of annotation and its index. In the construction phase of the concordance, all the annotations are first grouped together by type (e.g., all footnotes, then all the comments by editor A, then all comments by editor B, etc.), and are then numbered sequentially. A small table T can be used to identify annotations of a certain type with the corresponding range in the enumeration. The general form of the extended coordinate could thus be (a; d; p; s; w; tag), with tag = 0 for words of the main text4. For the example in (2), the (w; tag) part of the coordinates of the words from left to right would be: (1; 0), (2; 0), (3; 0), (4; 1), (5; 1), (4; 2), (5; 2), (4; 0), (5; 0), (6; 0). Adding the tag, however, solves only part of the problem. Consider for example again the sentence in (2), and suppose the query to be processed is c2 (1; 1) a4. As a matter of fact, the words c2 and a4 are adjacent if annotations are embedded in the text, and thus the sentence should be retrieved under possibility 2. above. However, the relative index of c2 is 5, and that of a4 is 4, so that this sentence does not qualify for retrieval. Indeed, c2 appears at the end of an annotation to word a3, and a4 just happens to follow c2 of the embedded annotation. It may therefore be quite possible that there is no real connection between c2 and a4. This is just a typical example of the asymmetric aspect of the problem: annotations are text portions that are appended to some word in the text, 4The reason for appending the tag-field at the right, rather than at the left end of the coordinate is that the concordance is ordered lexicographically: having the tag at the left end would, for each word, group all its occurrences in annotations at the end of the list; with the tag at the right end, coordinates of annotation words appear close to coordinates of the words they might annotate. - 6 - and the annotation itself or some pointer to it generally appears immediately following the annotated word, rather than preceding it. There is thus a much stronger connection between the annotated word in the main text and the first words of the annotation, than between the last words of the annotation and the following words of the main text, especially if the annotation is long enough. The real question is therefore: How should we measure the distance between a word in an embedded annotation and a word that occurs later in the main text? Refer again to the example in (2) and consider the distance from b2 to a4. The following four possibilities could be considered: (a) All the annotations to a single word w are ordered linearly and then embedded, as a single block, in the main text following w. In this case, the distance is 3, if the c-annotation follows the b-annotation. (b) The different annotations to a single word w are not ordered, but embedded in the text so as to form a partially ordered set. In this case, each annotation to w is individually embedded in the main text at w. The distance between any two words in two distinct annotations to w is defined as 1. The distance between b2 and a4, however, is 1. (c) One may derive the distance by referring to a common anchor in the main text, say a3: b2 being at distance 2 from a3 and a4 at distance 1, this would imply a distance of d(b2; a4) = d(a3; b2) \Gamma d(a3; a4) = \Gamma 1 from b2 to a4. Note that this distance is independent of the choice of anchor. (d) The same as (b), except that if the annotation is "long", then the distance between a word in the annotation at w and a word in the main text following w is defined as 1. Note, however, that the distance between a word preceding w and a word in the annotation at w is defined as in (b). Unfortunately, each of the four alternatives may be objected to. As to the first, it might not be reasonable to let the annotation c1 c2 interfere with evaluating the distance between b2 and a4: the physical order of placing the b-annotation before the c-annotation may be quite arbitrary. Therefore we don't pursue (a) any further. The second and third alternatives are symmetric in the sense that for (b), the distance between b2 and a4 depends on the length of the annotation, i.e., on the number of annotation words following b2, but not on the number of words preceding b2 in the same annotation, and conversely for (c). Alternative (d) is reasonable for long annotations, where there seems to be little semantic correlation, if any, between the tail end of the embedded annotation and the main text following it. But for short annotations, such as hyperlinks, possibility (b) seems preferable. One tends to consider short annotations, such as pointers or short footnotes, differently from long annotations, which may at times extend to several paragraphs. It is true that this notion of how to define a short or long annotation is a subjective one, but for our application, a subjective judgement is crucial, since it governs also the standard measures recall and precision. Both are defined in terms of the number of "relevant" items, and this relevance is assessed by means of the user's intuition. We should thus decide how to let the length of the annotation influence the retrieval process. - 7 - Fixing a global constant threshold seems not to be reasonable. Depending on laguage and context, the number of consecutive words that still are semantically related may greatly vary. An alternative would be to define a "short" annotation as one not extending beyong a single sentence. In that case, words belonging to a second or later sentence of a long annotation are very rarely connected to words in the main text following the annotation. There remains, however, the problem of defining what exactly should be considered as a sentence. Just basing this definition on the occurrence of certain punctuation signs may be misleading: certain authors, especially modern poets, use periods and commas very scarcely, if at all; on the other hand, not every dot ends a sentence, as can be seen by the hyperlinks displayed in the introduction. As another example, consider the words Hello! I said to Mr. Smith. This would be parsed as three instead of only one sentence, and even the more sophisticated rule of defining the end of a sentence by the appearance of a period (or exclamation point, etc) followed by a space and a capitalized letter, would fail in this case. Such problems in the definition of a sentence were reported for the Tr'esor de la Langue Fran,caise [5], a large French database, written entirely in upper case. A compromise could be to fix a small, rather arbitrary limit to the length of what we shall consider a short annotation, say, 20 words. Punctuation signs within these 20 words are ignored; longer annotations are still considered as a single textual unit, as long as no punctuation signs appear. It is of course easy to come up with examples for which this rule of thumb will fail, but in many cases it will help not to overlook relevant occurrences, and therby improve recall, but still filter out some unrelevant ones, and thus improve precision as well. 3.2 Implementation issues From the implementation point of view, possibility (c) is the easiest to implement, since the coordinate including the tag-field provides all the necessary information, and the distance can be computed by simple subtraction of the values in the word-fields of the coordinates. However, the fact that a word in an annotation at w has a negative distance to a word in the main text following w seems counter-intuitive. As to (b) and (d), we need, in addition to the tag in each coordinate, also knowledge about the length of each of the annotations, and their starting points. Note that knowing, for each annotation word w, the number of words within the same annotation following w, does not suffice to calculate the distance from w to some word in the main text. The problem is that we would not know, in certain cases, whether the word in the main text precedes or follows the one in the annotation. For example, the indices of b2 and a4 in a1 a2 a3 a4 b2 a5 a6 would be the same as in (2), and in both cases b2 is the last word of the annotation, but in (2) b2 precedes a4 and vice versa here. For possibilities (b) and (d), the coordinates of words in annotations have thus to be further extended to the form (a; d; p; s; w; tag; strt; len), with strt being the index of the annotated word in the main text, and len the length (in words) of the annotation the current coordinate belongs to. Since generally, the total amount of annotations is small - 8 - relative to the main text, having additional fields in the corresponding coordinates is not a considerable overhead. Consider the query a3 (1; 3) b3 applied to a text including the sentence a1 a2 a3 b1 b2 \Delta \Delta \Delta b8 b9 = a3 b10 a4 a5 = b3 a6 a7 where the words b1 \Delta \Delta \Delta b10 constitute an annotation and b9 and a3 are occurrences of the same word, and similarly for a5 and b3. Under (d), considering the annotation as a long one, the first instance, with a3 in the main text and b3 in the annotation, is retrieved, but the second, where a3 is in the annotation and b3 in the main text, is not retrieved. Note that in the implementation, it does not suffice to base the retrieval criterion on that the first word (a3) be in the main text and the second (b3) not, since the above query is equivalent to b3 (\Gamma 3; \Gamma 1) a3, and should therefore produce the same results. We should thus redefine the notion of the distance d(x; y) between words x and y, by means of the procedure in Figure 1. It corresponds to possibility (b), which takes the embedded annotation words into account. Note, however, that the distance between two words belonging both to the main text, ignores all annotations. We assume here the default level, i.e., that the distance is measured in words. Therefore, if the author, document, paragraph and sentence fields of the given coordinates do not match, the distance between them is defined as infinity, so that in any case the constraints li ^ d(x; y) ^ ui will not be satisfied. Note that the definition of the distance is straightforward if both words are in the main text or in the same annotation, and also in the case where one of the words, say x, is in the main text, and the other is in an annotation to a word of the main text that follows x. In the other cases, the definition of the distance involves also the len and strt fields. In the special case in which both x and y are in different annotations to the same point of the main text, the distance is set to 1, since there are two just as plausible interpretations. For instance, in (2), d(b1; c2) could be 3 as well as \Gamma 1, depending on whether we consider the annotation b1 b2 as preceding or as following c1 c2. However, if b1 and c2 are in annotations to different main text words w1, w2, then the distance between them is finite even if the query is restricted to annotations only and excludes the main text, when the main text serves only as a "catalyst". The general retrieval procedure is given in Figure 2. For the ease of description, we assume here that the keywords are processed from left to right, from A1 to Am (see (1)). In reality, the order may depend on the number of coordinates of each of the keywords, since much CPU time and many accesses to secondary storage may be saved if we start first with the rare keywords. On the other hand, it is not always possible to process the keywords in increasing order of the number of their occurrences, because of the varying metrical constraints. For example, if in the query "A (2,3) B (1,3) C" the keyword A is the one with the lowest number of occurrences, then the next one to be dealt with should be B even if C has less occurrences than B. If we would deal first with C, assuming that it must appear between 3 to 6 words after A, and only then turn to look for B, 1 to 3 words before C, then the following string would be retrieved: ": : : x A x x x B x C x : : :"; however, it does not satisfy the query because the distance from A to B is 4. Hence the order of processing the keywords is more restricted. In fact, at any stage, one of the keywords can be chosen which is adjacent to one of those already handled. For more details on this procedure, the reader is referred to [2]. - 9 - Distance function d(x; y) f if a(x) 6= a(y) or d(x) 6= d(y) or p(x) 6= p(y) or s(x) 6= s(y) /* if not same author, document, paragraph and sentence */ d(x; y) \Gamma 1 else if tag(x) = tag(y) /* both in main text or in same annotation */ d(x; y) \Gamma w(y) \Gamma w(x) else if tag(x) ? 0 and tag(y) = 0 /* y in main text; x in annotation */ if strt(x) ! w(y) /* annotated word precedes y */ d(x; y) \Gamma (len(x) \Gamma w(x)) + (w(y) \Gamma strt(x)) else /* annotated word follows y */ d(x; y) \Gamma w(y) \Gamma w(x) /* which is negative */ else if tag(y) ? 0 and tag(x) = 0 /* x in main text; y in annotation */ if strt(y) ! w(x) /* annotated word precedes x */ d(x; y) \Gamma \Gamma [(len(y) \Gamma w(y)) + (w(x) \Gamma strt(y))] else /* annotated word follows x */ d(x; y) \Gamma w(y) \Gamma w(x) else /* both x and y in annotations, but in different ones */ if strt(x) = strt(y) /* annotating same word */ d(x; y) \Gamma 1 else if strt(x) ! strt(y) d(x; y) \Gamma (len(x) \Gamma w(x)) + (w(y) \Gamma strt(x)) else /* strt(x) ? strt(y) */ d(x; y) \Gamma \Gamma [(len(y) \Gamma w(y)) + (w(x) \Gamma strt(y))] g Figure 1: Distance evaluation algorithm - 10 - Query processing f Partial-Solution(1) \Gamma Sn 1j =1 C(A1j) for i \Gamma 2 to m for j \Gamma 1 to ni for all (: : : ; x) 2 Partial-Solution(i \Gamma 1) for all y 2 C(Aij) if li\Gamma 1 ^ d(x; y) ^ ui\Gamma 1 add (: : : ; x; y) to Partial-Solution(i) Solution \Gamma Partial-Solution(m) g Figure 2: Query processing algorithm 3.3 Alternative implementation We have so far considered the possibility of extending the coordinate structure to solve our problem of information retrieval in the presence of annotations. If most of the user queries restrict their attention to the main text, it might be more efficient to construct not only one, but two or several concordances. There would be one concordance for the main text, and another for all the words within annotations, or, if the annotations are of several kinds, one could even consider having a separate concordance for each type of annotation. Different time/space tradeoffs are involved in this choice, and the usefulness of each of the methods may depend on the types of the most popular queries. Having the annotations in separate concordances will reduce the necessary storage space, since no tags are needed. On the other hand, every query, unless specifically restricted to the main text alone, will now have to search (and thus access) several files. The coordinates of annotation words will still have to include also an exact reference to the annotated word, so as to permit the retrieval of text portions in which part of the keywords appear in the main text, and part in one or several annotations. 4. Conclusion and future work We have presented some approaches to the problem of dealing with annotations in fulltext retrieval systems, or in general hypertext environments, in which the hyperlinks themselves are considered as searchable text. The goals were: (i) to improve the retrieval performance by discovering more relevant items; and (ii) at the same time to reduce the number of non-relevant items that will be retrieved; and (iii) to permit selective retrieval, ignoring at times all the annotations, concentrating at others exclusively on certain subsets - 11 - of annotations. As a testbed we shall use the databases of the Responsa Retrieval Project [3], a corpus including, among others, the Bible, the Talmud, Maimonides' Code and hundreds of other Hebrew and Aramaic texts, written over the last ten centuries all over the world. This text collection is characterized by a high degree of self- and crossreferences, and by various layers of annotations, consisting of comments, and comments on earlier comments, etc. The way to check the effectiveness of the extension of the concordance structure is by comparing recall and precision on a large set of queries, with and without the special treatment of the annotations. As to queries restricting the search to the main text or only certain types of annotations, we anticipate, in addition to improvements in retrieval performance, also substantial savings in the response time of an on-line retrieval system. References [1] Agosti M., Melucci M., Crestani F., Automatic authoring and construction of hypermedia for information retrieval, Multimedia Systems 3 (1995) 15-24. [2] Choueka Y., Fraenkel A.S., Klein S.T., Segal E., Improved Techniques for Processing Queries in Full-Text Systems, Proc. 10-th ACM-SIGIR Conf., New Orleans (1987) 306-315. [3] Fraenkel A.S., All about the Responsa Retrieval Project you always wanted to know but were afraid to ask, Expanded Summary, Jurimetrics J. 16 (1976) 149-156. [4] DeBra P., Houben G., Kornatzky Y., Post R., Information retrieval in distributed Hypertexts, Proc. 4th RIAO-94 Conference, New-York (1994) 481-491. [5] Klein S.T., Bookstein A., Deerwester S., Storing Text Retrieval Systems on CD-ROM: Compression and Encryption Considerations, ACM Trans. on Information Systems 7 (1989) 230-245. [6] Nielsen J., Hypertext and Hypermedia, Academic Press Professional, Boston (1993). [7] Salton G., McGill M.J., Introduction to Modern Information Retrieval , McGraw Hill, New York (1983). - 12 -