Embodiment
In order to retrieve the document that the retrieval participle occurs at desired location; The embodiment of the invention provides a kind of document retrieval method; In this method; After receiving retrieval request; Need one or more retrieval participles that search key comprised (the being specific retrieval participle) condition that residing position need be satisfied in destination document in the deterministic retrieval request, search the document that this condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place then, at last the information of the document that finds is returned as result for retrieval.
Referring to Fig. 1, the document retrieval method that the embodiment of the invention provides specifically may further comprise the steps:
Step 10: receive the retrieval request that comprises search key;
Here, search key is meant the keyword that is used to retrieve of the external world (for example user) input;
Step 11: confirm retrieval participle that said search key comprises and the specific retrieval participle condition that residing position need be satisfied in destination document in this retrieval participle;
Step 12: search the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place;
Step 13: the information of the document that finds is returned as result for retrieval.
In the step 11, when said specific retrieval participle comprises first retrieval participle that search key comprises, confirm this first retrieval participle condition that residing position need be satisfied in destination document, its concrete realization can be following:
Form according to search key; The position of first retrieval participle that the deterministic retrieval keyword is comprised in destination document and the required satisfied primary importance relation of reference position of destination document concern first retrieval participle condition that residing position need be satisfied in destination document as search key comprised with this primary importance.
Concrete, the concrete realization of above-mentioned definite primary importance relation can be following:
At first, confirm in search key, whether to have asterisk wildcard before first retrieval participle; Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and distance value scope; Confirm the corresponding position distance value of first retrieval participle asterisk wildcard before, and confirm that said primary importance relation is: the distance value between the bebinning character of first retrieval participle and destination document described in the destination document is in said distance value scope; When confirming as not, confirm that said primary importance relation is: first retrieval participle is positioned at the reference position of destination document.
Certainly, above-mentioned form according to search key confirms that the realization of primary importance relation is not limited to the mode of above-mentioned asterisk wildcard, and any other form according to search key confirms that the mode of primary importance relation is all in protection scope of the present invention.
In the step 11, when said specific retrieval participle comprises last retrieval participle that search key comprises, confirm this last retrieval participle condition that residing position need be satisfied in destination document, its concrete realization can be following:
Form according to search key; The position of last retrieval participle that the deterministic retrieval keyword is comprised in destination document and the required satisfied second place relation of end position of destination document concern last the retrieval participle condition that residing position need be satisfied in destination document as search key comprised with this second place.
Concrete, the concrete realization of above-mentioned definite second place relation can be following:
Confirm in search key, whether to have asterisk wildcard after last retrieval participle; Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and position distance value; Confirm the corresponding distance value scope of last retrieval participle asterisk wildcard afterwards, and confirm that said second place relation is: the distance value between the ending character of last retrieval participle and destination document described in the destination document is in said distance value scope; When confirming as not, confirm that said second place relation is: last retrieval participle is positioned at the end position of destination document.
Certainly, above-mentioned form according to search key confirms that the realization of second place relation is not limited to the mode of above-mentioned asterisk wildcard, and any other form according to search key confirms that the mode of second place relation is all in protection scope of the present invention.
Illustrate, when said asterisk wildcard was asterisk, said distance value scope was to be not less than 0 integer; When said asterisk wildcard was question mark, the distance value scope that said question mark is corresponding was 0 or 1.
In step 10, receive and comprise before the retrieval request of search key, can set up index file, comprise retrieval participle and the positional information of this retrieval participle in corresponding document that each document comprises in this index file to one or more documents;
Accordingly, the concrete realization of step 12 can be divided into following three kinds of situation:
First kind, corresponding to specific retrieval participle comprise in the search key first the retrieval participle situation, specific as follows:
At first, confirm to comprise the document of the whole retrieval participles in the search key according to said index file; Then; From said index file, read first retrieval participle positional information in the document in the search key, confirm according to this positional information whether the reference position of this first position of retrieval participle in the document and the document satisfies said primary importance and concern; If; Then the document is confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds; Otherwise, the document is not confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds.
Second kind, corresponding to specific retrieval participle comprise in the search key last the retrieval participle situation, specific as follows:
At first, confirm to comprise the document of the whole retrieval participles in the search key according to said index file; Then; From said index file, read last the retrieval participle positional information in the document in the said search key, confirm according to this positional information whether the reference position of this last retrieval participle position in the document and the document satisfies the said second place and concern; If; Then the document is confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds; Otherwise, the document is not confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds.
The third comprises the situation of first and last the retrieval participle in the search key corresponding to specific retrieval participle, and is specific as follows:
At first, confirm to comprise the document of the whole retrieval participles in the search key according to said index file; Then; From said index file, read first retrieval participle and the positional information of last retrieval participle in the document in the search key; Whether the reference position of confirming this first retrieval participle position and the document in the document according to the positional information that reads satisfies said primary importance relation, and whether the end position of this last retrieval participle position and the document in the document satisfies the said second place and concern; If; Then the document is confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds; Otherwise, the document is not confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds.
Certainly; Specific retrieval participle except can comprise in the search key first with last the retrieval participle; Also can comprise any other retrieval participle in the search key; In this case; The concrete realization of confirming this specific retrieval participle condition that residing position need be satisfied in destination document in the step 11 can be following: according to the form of search key, confirm the position of this specific retrieval participle in destination document and the reference position and/or the required satisfied position of the end position relation of destination document, this position is concerned as this specific retrieval participle condition that residing position need be satisfied in destination document.Accordingly, the concrete realization of step 12 can be following: at first, confirm to comprise the document of the whole retrieval participles in the search key according to index file; Then, from index file, read the positional information of this specific retrieval participle in the document, confirm according to this positional information whether reference position of this specific retrieval participle position and the document in the document and/or end position satisfy corresponding position relation; If; Then the document is confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds; Otherwise, the document is not confirmed as the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place that finds.
Preferable, between step 12 and step 13, this method further comprises:
Confirm whether consistent the position relation of participle in the document that finds of respectively retrieving that said search key comprises concerns with position in said search key;
Accordingly, in the step 13, during with position relationship consistency in said search key, the information of the document that finds is returned as result for retrieval in the position relation in the document that participle finding respectively retrieved of confirming that said search key comprised.
Preferable, between step 12 and step 13, can each document that find be sorted according to the data length of the position of retrieval participle in each document that finds that search key comprised and each document that finds; Accordingly, in the step 13,, each document that finds is returned as result for retrieval according to the ranking results that each document that finds is sorted.
Above-mentioned data length according to the position of retrieval participle in each document that finds that said search key comprised and each document that finds sorts to each document that finds, and its concrete realization can be following:
At first, according to predefined file correlation value computing formula, calculate the relevance degree of each document that finds respectively; Said file correlation value computing formula meets the following conditions: the position of retrieval participle in document that said search key comprised is forward more; The relevance degree that calculates according to the document relevance degree computing formula is big more; The data length of document is more little, and the relevance degree that calculates according to the document relevance degree computing formula is big more;
Then, the size order according to the relevance degree of each document that calculates sorts each document.
Said file correlation value computing formula can comprise:
Formula one:
Formula two:
Wherein, scord (d) is the file correlation value of document d; Len is the data length of document, and pos (t) is the positional value of t retrieval participle in document that said search key comprised, and N is the number of the retrieval participle that said search key comprised.
Certainly; File correlation value computing formula is not limited to above-mentioned formula one and formula two; Any formula with following characteristic is all in protection scope of the present invention: the position of retrieval participle in document that search key comprised is forward more; The result of calculation value is big more, and the data length of document is more little, and the result of calculation value is big more.
In order can result for retrieval to be sorted according to position and the data length of document that the retrieval participle appears in the document; The embodiment of the invention provides a kind of document retrieval method; In this method; After retrieving a plurality of documents that comprise the whole retrieval participles in the search key,, a plurality of documents that retrieve are sorted according to the data length of the position of the retrieval participle in the search key in a plurality of documents that retrieve with a plurality of documents that retrieve; Last a plurality of documents that will retrieve according to ranking results return as result for retrieval.
Referring to Fig. 2, the document retrieval method that the embodiment of the invention provides specifically may further comprise the steps:
Step 20: retrieval comprises a plurality of documents of the whole retrieval participles in the search key;
Here; Can be to retrieve a plurality of documents that comprise the whole retrieval participles in the search key according to above-mentioned steps 10-12; Also can be to retrieve a plurality of documents that comprise the whole retrieval participles in the search key according to prior art, prior art be: after receiving retrieval request, analyze the retrieval participle that the search key in the deterministic retrieval request comprises; Search in the indexed file comprise all the retrieval participles document, and with the document as result for retrieval.
Step 21:, a plurality of documents that retrieve are sorted according to the data length of the position of the retrieval participle in the said search key in a plurality of documents that retrieve with a plurality of documents that retrieve;
Step 22:, a plurality of documents that retrieve are returned as result for retrieval according to the ranking results that a plurality of documents that retrieve are sorted.
The concrete implementation of step 21 can be following:
According to predefined file correlation value computing formula, calculate the relevance degree of a plurality of documents that retrieve respectively; Said file correlation value computing formula meets the following conditions: the position of retrieval participle in document that said search key comprised is forward more; The relevance degree that calculates according to the document relevance degree computing formula is big more; The data length of document is more little, and the relevance degree that calculates according to the document relevance degree computing formula is big more;
Size order according to the relevance degree of a plurality of documents that calculate should sort by a plurality of documents.
Above-mentioned file correlation value computing formula can adopt above-mentioned formula one and formula two.Certainly; File correlation value computing formula is not limited to above-mentioned formula one and formula two; Any formula with following characteristic is all in protection scope of the present invention: the position of retrieval participle in document that search key comprised is forward more; The result of calculation value is big more, and the data length of document is more little, and the result of calculation value is big more.
In the practical application, under the identical situation of file correlation value, can further press predefined rule, as press rules such as phonetic, ISN, the document that the file correlation value is identical sorts.
Below in conjunction with embodiment the present invention is specified:
Embodiment one:
Present embodiment is that process set up in index, and is specific as follows:
Step 01: field that accurate Search Requirement is arranged in the document by the word participle, is obtained one or more retrieval participles, is that index created in each retrieval participle;
Step 02: in index, increase additional markers (Term), with the ending of tag field.The text of Term adopts a predefine character END.END is a unallowable instruction digit in the character code set, to guarantee to follow normal text generating to repeat;
Step 03: write down and preserve the length of this field of each document, i.e. the retrieval participle number that comprises of this field, the length value greater than 255 is handled as 255, with convenient storage with calculate.
Embodiment two:
Present embodiment is the file retrieval process, and is specific as follows:
Step 11: the search key in the retrieval request is pressed the word participle, obtain N retrieval participle.If relate to the position relation that ends up with field, extra interpolation END is as N+1 retrieval participle;
Step 12: resolve search key and asterisk wildcard wherein, obtain and write down the position of respectively retrieving between the participle concerning, comprising:
The position relation that first retrieval participle and document start, the position relation between second retrieval participle and first retrieval participle ..., N the position relation of retrieving between participle and the document ending;
Position relation can represent with one group of minimum position value and maximum position value, remember and do (min, max).The minimum value of min is 0, and promptly the position is identical, and the maximal value of max is MAX, can be decided to be 255 here.
Step 13: from the index of creating, search qualified document;
Specific to; Find the document that comprises above-mentioned N+1 retrieval participle simultaneously; And then from index file, read the positional value of N retrieval participle in the document, and carry out the concrete coupling of position relation, require the relative position of this N+1 retrieval participle in document to meet above-mentioned required distance.
Step 14: the relevance degree of the document that calculating finds according to the relevance degree computing formula, carry out descending sort according to relevance degree to the document that finds.The relevance degree computing formula adopts above-mentioned formula one and formula two.
Embodiment three:
Present embodiment is explained embodiment through in enterprise's retrieve application to the realization that the entry field of " Ci hai " is retrieved.
The retrieval requirement that " Ci hai " entry field is carried out can be found at ad-hoc location and comprise the document of retrieving participle, and according to hit location and hit document length, uses above-mentioned rule compositor.
Support in the retrieval request asterisk wildcard "? " " * ", wherein "? " Represent 0 or 1 character, and " * " represents 0 or one or more characters, is supported in the search key to have a plurality of asterisk wildcards simultaneously.
Below be the illustrated in detail that various types of asterisk wildcards are used:
In retrieving, should mate the position relation between the retrieval participle, also to mate the position relation between beginning of retrieval participle and document and the ending.
Before retrieval, need carry out index and set up process, specific as follows: as entry field to be pressed the word participle, create inverted index.In index, increase additional markers (Term), with the ending of tag field.The text of Term adopts a predefine character END.END is a unallowable instruction digit in the character code set, to guarantee to follow normal text generating to repeat; Record is also preserved the length of this field of each document, i.e. the retrieval participle number that comprises of this field, and the length value greater than 255 is handled as 255, uses a byte (byte) to preserve field length.
Be example with retrieval "? AB*C " below, the description retrieving:
Step 21: to set up process corresponding with index, and the search key in the retrieval request is pressed the word participle, obtains " A ", " B ", " C " three retrievals participle, increases an ending END as required as the 4th retrieval participle.
Step 22: calculate retrieval participle position relation each other, and the retrieval participle concerns with position between document beginning, the document ending.
Position relation representes with a pair of lowest distance value min and maximum range value max, remember and do (min, max), the min minimum value is 0, promptly the position is identical; The maximal value of max is MAX.In the retrieval request asterisk wildcard "? " Represent 0 or 1 character, " * " represents 0 or one or more characters.
After resolving retrieval request, obtain following distance relation:
Dis(BEGIN,A)=(0,1)
Dis(A,B)=(1,1)
Dis(B,C)=(1,MAX)
Dis(C,FINALITY)=(1,1)
BEGIN representes the beginning of document, and FINALITY representes the ending of document.Dis (X, Y) represent with minor increment and ultimate range by expression X, Y distance relation between the two.MAX is predefined maximum range value, is decided to be 255 here.
Step 23: from inverted index, search document;
At first search simultaneously the document that comprises " A ", " B ", " C " three retrievals participle, and then read these retrieval participle and the positional value of END in the document, carry out the concrete coupling of position relation.
Require the relative position of three retrieval participles in document to meet above-mentioned required distance.The positional value of " A " is necessary for 0 or 1, thereby satisfies the position relation that starts with document, and " A ", " B ", " C ", " END " position relation each other also satisfies above-mentioned required distance.
Step 24: calculate the relevance degree of qualified each document retrieve according to the relevance degree computing formula, the document that retrieves according to relevance degree rank order from high to low, and is returned the result after the ordering.
Here according to " A ", " B ", the positional value of " C " and the length of document field, carry out the calculating of relevance degree.
The present invention can also be applied in the Database Systems; With a record in the database as a document; After receiving the retrieval request that comprises search key, search the record that certain condition is satisfied in position that record field comprises retrieval participle and the specific retrieval participle place in the search key.
Referring to Fig. 3, the embodiment of the invention provides a kind of document retrieving apparatus, and this device comprises:
Request receiving element 30 is used to receive the retrieval request that comprises search key;
Condition analysis unit 31 is used for confirming the retrieval participle that said search key is comprised and the specific retrieval participle condition that residing position need be satisfied in destination document of this retrieval participle;
File search unit 32 is used to search the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place;
The result returns unit 33, is used for the information of the document that finds is returned as result for retrieval.
Further, said condition analysis unit 31 specifically can be used for:
When said specific retrieval participle comprises first retrieval participle that said search key comprises; Form according to said search key; Confirm the position of first retrieval participle in destination document and the required satisfied primary importance relation of reference position of destination document that said search key comprises, this primary importance relation is retrieved participle condition that residing position need be satisfied in destination document as said first;
Accordingly, said file search unit 32 specifically can be used for:
Search and comprise the document that definite retrieval participle and said first retrieval participle satisfy said primary importance relation.
Further, said condition analysis unit 31 specifically can be used for:
When said specific retrieval participle comprises last retrieval participle that said search key comprises; Form according to said search key; Confirm the position of last retrieval participle in destination document and the required satisfied second place relation of end position of destination document that said search key comprises, this second place is concerned as said last retrieval participle condition that residing position need be satisfied in destination document;
Accordingly, said file search unit 32 specifically can be used for:
Search and comprise the document that definite retrieval participle and said last retrieval participle satisfy said second place relation.
Further, said condition analysis unit 31 specifically can be used for:
Form according to said search key; Confirm the position of first retrieval participle in destination document and the required satisfied primary importance relation of reference position of destination document that said search key comprises, and the position of last retrieval participle that said search key comprised in destination document and the required satisfied second place relation of end position of destination document;
Accordingly, said file search unit 32 specifically can be used for:
Search and comprise definite retrieval participle and said first retrieval participle and satisfy the document that said primary importance relation and said last retrieval participle satisfy said second place relation.
Further, said condition analysis unit 31 specifically can be used for:
Confirm in said search key, whether to have asterisk wildcard before first retrieval participle;
Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and distance value scope; Confirm the position distance value that said asterisk wildcard is corresponding, and confirm that said primary importance relation is: the distance value between the bebinning character of first retrieval participle and destination document described in the destination document is in said distance value scope;
When not confirming as not, confirm that said first retrieval participle position in destination document and the required satisfied primary importance relation of the reference position of destination document are: first retrieves the reference position that participle is positioned at destination document.
Further, said condition analysis unit 31 specifically can be used for:
Confirm in said search key, whether to have asterisk wildcard after last retrieval participle;
Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and position distance value; Confirm the distance value scope that said asterisk wildcard is corresponding, and confirm that said second place relation is: the distance value between the ending character of last retrieval participle and destination document described in the destination document is in said distance value scope;
When not confirming as not, confirm that said last retrieval participle position in destination document and the required satisfied second place relation of the end position of destination document are: last retrieves the end position that participle is positioned at destination document.
When said asterisk wildcard was asterisk, said distance value scope was to be not less than 0 integer; When said asterisk wildcard was question mark, the distance value scope that said question mark is corresponding was 0 or 1.
Further, said file search unit 32 also can be used for:
Confirm whether consistent the position relation of participle in the document that finds of respectively retrieving that said search key comprises concerns with position in said search key;
Further, said result returns unit 33 and specifically can be used for:
, the information of the document that finds is returned as result for retrieval during in the position relation in the document that participle finding respectively retrieved of confirming that said search key comprised with position relationship consistency in said search key.
Further, this device also comprises:
Sort result unit 34, the retrieval participle that is used for comprising according to said search key sorts to each document that finds at the position of each document that finds and the data length of each document that finds;
Accordingly, said result returns unit 33 and specifically can be used for:
According to the ranking results that each document that finds is sorted, each document that finds is returned as result for retrieval.
Further, said sort result unit 34 specifically can be used for:
According to predefined file correlation value computing formula, calculate the relevance degree of each document that finds respectively; Said file correlation value computing formula meets the following conditions: the position of retrieval participle in document that said search key comprised is forward more; The relevance degree that calculates according to the document relevance degree computing formula is big more; The data length of document is more little, and the relevance degree that calculates according to the document relevance degree computing formula is big more;
Size order according to the relevance degree of each document that calculates sorts each document.
Said file correlation value computing formula can for:
Wherein, scord (d) is the file correlation value of document d; Len is the data length of document, and pos (t) is the positional value of t retrieval participle in document that said search key comprised, and N is the number of the retrieval participle that said search key comprised.
Referring to Fig. 4, the embodiment of the invention also provides a kind of document retrieving apparatus, and this device comprises:
Document retrieving unit 40 is used for retrieving a plurality of documents of the whole retrieval participles that comprise search key;
Sort result unit 41 is used for according to the position of retrieval participle in a plurality of documents that retrieve of said search key and the data length of a plurality of documents that retrieve a plurality of documents that retrieve being sorted;
The result returns unit 42, is used for the ranking results that sorts according to a plurality of documents that retrieve, and a plurality of documents that retrieve are returned as result for retrieval.
Further, said sort result unit 41 specifically can be used for:
According to predefined file correlation value computing formula, calculate the relevance degree of a plurality of documents that retrieve respectively; Said file correlation value computing formula meets the following conditions: the position of retrieval participle in document that said search key comprised is forward more; The relevance degree that calculates according to the document relevance degree computing formula is big more; The data length of document is more little, and the relevance degree that calculates according to the document relevance degree computing formula is big more;
Size order according to the relevance degree of a plurality of documents that calculate should sort by a plurality of documents.
Said file correlation value computing formula can for:
Wherein, scord (d) is the file correlation value of document d; Len is the data length of document, and pos (t) is the positional value of t retrieval participle in document that said search key comprised, and N is the number of the retrieval participle that said search key comprised.
Further, said document retrieving unit 40 comprises:
The request receiving element is used to receive the retrieval request that comprises search key;
The condition analysis unit is used for confirming the retrieval participle that said search key is comprised and the specific retrieval participle condition that residing position need be satisfied in destination document of this retrieval participle;
The file search unit is used to search the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place;
The result returns the unit, is used for the information of a plurality of documents that find is returned as result for retrieval.
Further, said condition analysis unit is used for:
When said specific retrieval participle comprises first retrieval participle that said search key comprises; According to the form of said search key, confirm the position of first retrieval participle in destination document and the required satisfied primary importance relation of reference position of destination document that said search key comprises;
Accordingly, said file search unit is used for:
Search and comprise the document that definite retrieval participle and said first retrieval participle satisfy said primary importance relation.
Further, said condition analysis unit is used for:
When said specific retrieval participle comprises last retrieval participle that said search key comprises; According to the form of said search key, confirm the position of last retrieval participle in destination document and the required satisfied second place relation of end position of destination document that said search key comprises;
Accordingly, said file search unit is used for:
Search and comprise the document that definite retrieval participle and said last retrieval participle satisfy said second place relation.
Further, said condition analysis unit specifically can be used for:
Form according to said search key; Confirm the position of first retrieval participle in destination document and the required satisfied primary importance relation of reference position of destination document that said search key comprises, and the position of last retrieval participle that said search key comprised in destination document and the required satisfied second place relation of end position of destination document;
Accordingly, said file search unit specifically can be used for:
Search and comprise definite retrieval participle and said first retrieval participle and satisfy the document that said primary importance relation and said last retrieval participle satisfy said second place relation.
Further, said condition analysis unit specifically can be used for:
Confirm in said search key, whether to have asterisk wildcard before first retrieval participle;
Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and distance value scope; Confirm the position distance value that said asterisk wildcard is corresponding, and confirm that said primary importance relation is: the distance value between the bebinning character of first retrieval participle and destination document described in the destination document is in said distance value scope;
When not confirming as not, confirm that said first retrieval participle position in destination document and the required satisfied primary importance relation of the reference position of destination document are: first retrieves the reference position that participle is positioned at destination document.
Further, said condition analysis unit specifically can be used for:
Confirm in said search key, whether to have asterisk wildcard after last retrieval participle;
Confirming as when being; Corresponding relation according to predefined asterisk wildcard type and position distance value; Confirm the distance value scope that said asterisk wildcard is corresponding, and confirm that said second place relation is: the distance value between the ending character of last retrieval participle and destination document described in the destination document is in said distance value scope;
When not confirming as not, confirm that said last retrieval participle position in destination document and the required satisfied second place relation of the end position of destination document are: last retrieves the end position that participle is positioned at destination document.
When said asterisk wildcard was asterisk, said distance value scope was to be not less than 0 integer; When said asterisk wildcard was question mark, the distance value scope that said question mark is corresponding was 0 or 1.
Further, said file search unit also can be used for:
Confirm whether consistent the position relation of participle in the document that finds of respectively retrieving that said search key comprises concerns with position in said search key;
Accordingly, said result returns the unit and specifically can be used for:
, the information of the document that finds is returned as result for retrieval during in the position relation in the document that participle finding respectively retrieved of confirming that said search key comprised with position relationship consistency in said search key.
To sum up, beneficial effect of the present invention comprises:
In the scheme that the embodiment of the invention provides; After receiving the retrieval request that comprises search key; Confirm retrieval participle that said search key comprises and the specific retrieval participle condition that residing position need be satisfied in destination document in this retrieval participle; Search the document that said condition is satisfied in the position that comprises definite whole retrieval participles and specific retrieval participle place, and the information of the document that finds is returned as result for retrieval.It is thus clear that the document of certain condition is satisfied in the position of adopting the present invention can retrieve the retrieval participle, also promptly can retrieve the document that the retrieval participle occurs at certain position, and then make result for retrieval more accurate, better meet user's request.
In the scheme that the embodiment of the invention provides; After retrieving a plurality of documents that comprise the whole retrieval participles in the search key; According to the data length of the position of the retrieval participle in the said search key in a plurality of documents that retrieve with a plurality of documents that retrieve; A plurality of documents to retrieving sort, and according to the ranking results that a plurality of documents that retrieve are sorted, a plurality of documents that retrieve are returned as result for retrieval.It is thus clear that, adopt the present invention, can result for retrieval be sorted according to position and the data length of document that the retrieval participle appears in the document, and then make that the ranking results of search file is more accurate, better meet user's request.
The present invention is that reference is described according to the process flow diagram and/or the block scheme of method, equipment (system) and the computer program of the embodiment of the invention.Should understand can be by the flow process in each flow process in computer program instructions realization flow figure and/or the block scheme and/or square frame and process flow diagram and/or the block scheme and/or the combination of square frame.Can provide these computer program instructions to the processor of multi-purpose computer, special purpose computer, Embedded Processor or other programmable data processing device to produce a machine, make the instruction of carrying out through the processor of computing machine or other programmable data processing device produce to be used for the device of the function that is implemented in flow process of process flow diagram or a plurality of flow process and/or square frame of block scheme or a plurality of square frame appointments.
These computer program instructions also can be stored in ability vectoring computer or the computer-readable memory of other programmable data processing device with ad hoc fashion work; Make the instruction that is stored in this computer-readable memory produce the manufacture that comprises command device, this command device is implemented in the function of appointment in flow process of process flow diagram or a plurality of flow process and/or square frame of block scheme or a plurality of square frame.
These computer program instructions also can be loaded on computing machine or other programmable data processing device; Make on computing machine or other programmable devices and to carry out the sequence of operations step producing computer implemented processing, thereby the instruction of on computing machine or other programmable devices, carrying out is provided for being implemented in the step of the function of appointment in flow process of process flow diagram or a plurality of flow process and/or square frame of block scheme or a plurality of square frame.
Although described the preferred embodiments of the present invention, in a single day those skilled in the art get the basic inventive concept could of cicada, then can make other change and modification to these embodiment.So accompanying claims is intended to be interpreted as all changes and the modification that comprises preferred embodiment and fall into the scope of the invention.
Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, belong within the scope of claim of the present invention and equivalent technologies thereof if of the present invention these are revised with modification, then the present invention also is intended to comprise these changes and modification interior.