JP2008077673A - Structured document management system - Google Patents

Structured document management system Download PDF

Info

Publication number
JP2008077673A
JP2008077673A JP2007272912A JP2007272912A JP2008077673A JP 2008077673 A JP2008077673 A JP 2008077673A JP 2007272912 A JP2007272912 A JP 2007272912A JP 2007272912 A JP2007272912 A JP 2007272912A JP 2008077673 A JP2008077673 A JP 2008077673A
Authority
JP
Japan
Prior art keywords
index
structured document
search
type
unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2007272912A
Other languages
Japanese (ja)
Other versions
JP4160627B2 (en
Inventor
Shunichi Ide
俊一 井手
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Toshiba Digital Solutions Corp
Original Assignee
Toshiba Corp
Toshiba Solutions Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp, Toshiba Solutions Corp filed Critical Toshiba Corp
Priority to JP2007272912A priority Critical patent/JP4160627B2/en
Publication of JP2008077673A publication Critical patent/JP2008077673A/en
Application granted granted Critical
Publication of JP4160627B2 publication Critical patent/JP4160627B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To maintain the strictness of retrieval while maintaining satisfactory update retrieval performance by constructing an index of a category suitable to an element in each element. <P>SOLUTION: A retrieval style processing part in a data retrieving part 16 analyzes a retrieval style given from the outside, extracts a retrieval condition and acquires a set of candidates for retrieval results satisfying the retrieval condition. A value extracting part in a retrieval managing part 15 acquires a history of retrieval conditions applied to a corresponding element in each element included in a structured document stored in a structured document DB 21. A retrieval category determining part in the retrieval managing part 15 determines a retrieval category on the basis of the largest retrieval category in history of retrieval conditions applied to the element in each element included in the structured document to which an index should be attached. An index constructing part in the retrieval managing part 15 constructs indexes of the retrieval category determined by the retrieval category determining part and stores the indexes in an N-gram search DB 22, word index DB 23 or B-tree index DB 24. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納するのに好適な、構造化文書管理システムに関する。   The present invention provides a structured document management system suitable for constructing an index of a structured document and storing it in the index storage means in order to speed up the search of the structured document stored in the structured document storage means. About.

近年、XML(Extensible Markup Language)に代表される、論理構造を有する構造化文書が普及している。構造化文書は、一般にディスク(ディスクドライブ)に配置されたデータベースに蓄積して利用される。   In recent years, structured documents having a logical structure represented by XML (Extensible Markup Language) have become widespread. Structured documents are generally stored and used in a database arranged on a disk (disk drive).

また、構造化文書の普及に伴い、1つまたは複数の構造化文書が蓄積されたデータベースから、ユーザの指定する検索条件に合致した文書または要素、属性、値などの情報を検索する情報検索システムが種々開発されている。この種の情報検索システムでは、検索対象の文書、更には文書内の要素や値などに、索引が付与されるのが一般的である(例えば、特許文献1参照)。   Further, with the spread of structured documents, an information retrieval system that retrieves information such as documents or elements, attributes, values, etc. that match a search condition specified by a user from a database in which one or more structured documents are accumulated Have been developed. In this type of information search system, an index is generally assigned to a document to be searched, and further to elements and values in the document (see, for example, Patent Document 1).

情報検索システムにおける構造化文書の検索では、構造、値またはそれらの組み合わせによる検索が行われる。この検索に適用される索引技術として、例えばNグラム(N−gram)を用いた索引技術(Nグラム索引技術)と、形態素解析を用いた索引技術(形態素索引技術)とが知られている。   In the retrieval of structured documents in the information retrieval system, retrieval is performed by structure, value, or a combination thereof. As an index technique applied to this search, for example, an index technique using N-gram (N-gram) (N-gram index technique) and an index technique using morphological analysis (morpheme index technique) are known.

Nグラム索引技術:
この技術では、文字列(値)の先頭から1文字ずつずらしながら、当該文字列を順にN文字(Nグラム)に区切り、この区切りにより生成された、それぞれN文字以下の文字列毎に索引(索引レコード)が作成される。これにより、例えばN=2で、値が“あいうえお”の場合であれば、“あ”/“あい”/“いう”/“うえ”/“えお”/“お”の6種類の索引(索引レコード)が作成される。この索引に対して、例えば“うえお”の部分文字列を含む値を検索する場合、まず索引をもとに、“うえ”と“えお”の位置を探索して、当該“うえ”と“えお”を含む文書と文書内の位置を特定し、それらが含まれる値の共通集合を検索結果の候補とする。
N-gram index technology:
In this technique, the character string is sequentially separated into N characters (N-grams) while being shifted one character at a time from the beginning of the character string (value), and an index ( Index record) is created. Thus, for example, if N = 2 and the value is “Aiueo”, six types of indexes “Ah” / “Ai” / “Nay” / “Up” / “Eo” / “O” ( Index record) is created. For example, when searching for a value including a partial character string “Ueo” for this index, first, based on the index, the positions of “Ue” and “Eo” are searched, and A document including “Eo” and a position in the document are specified, and a common set of values including these is set as a search result candidate.

形態素解析索引技術:
この技術では、値(文字列)から単語が抽出される。文字列を単語に区切る方法としては“形態素解析”が知られている。抽出された単語毎に、索引(索引レコード)が作成される。これにより、例えば“本日は晴天なり”の値に対しては、“本日”/“晴天”の2つの単語が抽出されて、それぞれ索引として作成される。この索引に対して、例えば“晴天”の部分文字列を検索する場合、まず索引をもとに“晴天”の位置を探索して、当該“晴天”を含む文書と文書内の位置を特定して検索結果の候補とする。
特開2003−30235(段落0030乃至0053、特に段落0044、図5)
Morphological analysis index technology:
In this technique, a word is extracted from a value (character string). As a method of dividing a character string into words, “morpheme analysis” is known. An index (index record) is created for each extracted word. Thus, for example, for the value “Today is sunny”, two words “Today” / “Sunny” are extracted and created as indexes. For example, when searching for a partial character string of “sunny sky” with respect to this index, the position of “sunny sky” is first searched based on the index, and the document including the “sunny sky” and the position in the document are specified. Search result candidates.
JP 2003-30235 (paragraphs 0030 to 0053, especially paragraph 0044, FIG. 5)

上述した従来の情報検索システムで適用される索引技術、例えばNグラムを用いた索引技術においては、索引量の増加を招き、総索引のサイズが、実装によっては原文サイズの10倍を超える巨大なものとなることがある。この場合、文書更新に伴う索引更新のディスク更新量が増え、更新性能が劣化する。また、検索においても、検索内容によっては索引探索のために必要なディスク参照量が増え、参照性能(検索性能)も劣化する。更に索引サイズが巨大なため、それを納めるだけの大きなディスク容量を準備する必要がある。   In the index technology applied in the above-described conventional information retrieval system, for example, an index technology using N-grams, the index amount increases, and the total index size is a huge size exceeding 10 times the original text size depending on the implementation. It can be a thing. In this case, the disk update amount of the index update accompanying the document update increases, and the update performance deteriorates. Also in the search, depending on the search contents, the disk reference amount required for the index search increases, and the reference performance (search performance) also deteriorates. Furthermore, since the index size is huge, it is necessary to prepare a large disk capacity to accommodate it.

一方、形態素解析を用いた索引技術においては、形態素解析で抽出されないような文字列を検索条件とすることはできないことから、厳密な検索は行うことができない。前述の例では、「“なり”を含む値を取得する」といった検索が要求された場合、正しい結果を得ることができない。   On the other hand, in an index technique using morphological analysis, a character string that cannot be extracted by morphological analysis cannot be used as a search condition, so that a strict search cannot be performed. In the above example, when a search such as “acquire a value including“ nari ”” is requested, a correct result cannot be obtained.

通常のアプリケーションで使用される検索は、厳密な検索が必要な場合(前者)と、若干厳密性が損なわれても構わないか、もしくは意味を持つ単語以外での検索が必要ない場合(後者)の2種類に大別される。前者の検索には、Nグラムによる索引技術が必要となるが、後者の検索には形態素解析による索引技術でも十分である。   Searches used in normal applications require a strict search (the former), a slight strictness of the search, or a search other than a meaningful word (the latter) There are two main types. An index technique based on N-grams is required for the former search, but an index technique based on morphological analysis is sufficient for the latter search.

また本発明者は、検索全般について考えた場合、厳密な検索で対象とするのは、題目やキーワード、人名、地名といったコンテンツの属性や書誌情報に分類されるようなデータであり、一般に文字列長は短い場合が多いことを認識するに至った。このようなデータは、記述の仕方にルールがあるのが一般的である。これに対し、例えば書誌の本文といったコンテンツの本体に分類されるデータは、一般に文字列長は長い。このように、書誌本文のような長大なデータでタグで細かく意味付けされていないようなデータは、厳密な検索や単語にならない文字列での検索が意味を持たない場合が多い。   In addition, when the present inventor considers the search in general, the object of the strict search is data that is classified into content attributes and bibliographic information such as title, keyword, person name, and place name, and is generally a character string. I came to realize that the length is often short. Such data generally has a rule in the way of description. On the other hand, for example, data classified into a content body such as a bibliographic text generally has a long character string length. As described above, in the case of long data such as a bibliographic text that is not detailed with tags, a strict search or a search with a character string that does not become a word often has no meaning.

本発明は上記事情を考慮してなされたものでその目的は、要素毎に、その要素に適した種別の索引を構築することにより、良好な更新検索性能を維持しながら検索の厳密性を維持することができる、構造化文書管理システムを提供することにある。   The present invention has been made in consideration of the above circumstances, and its purpose is to maintain the strictness of search while maintaining good update search performance by constructing an index of a type suitable for each element for each element. It is to provide a structured document management system that can do this.

本発明の1つの観点によれば、構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納する構造化文書管理システムが提供される。このシステムは、外部から与えられる検索式を解析して検索条件を抽出し、その検索条件に合致する検索結果の候補の集合を取得する検索式処理手段と、前記構造化文書格納手段に格納された構造化文書に含まれる各要素毎に、当該要素に対して適用された前記検索式処理手段によって抽出された検索条件の履歴を取得する検索履歴取得手段と、索引を付与すべき、構造化文書に含まれる各要素毎に、前記検索履歴取得手段によって取得された、当該要素に対して適用された検索条件の履歴において最も多い検索種別に基づいて索引種別を決定する索引種別決定手段と、前記索引種別決定手段によって前記各要素毎に決定された索引種別に基づいて、当該要素に対応する当該決定された索引種別の索引を構築して前記索引格納手段に格納する索引構築手段とを備える。   According to one aspect of the present invention, in order to speed up retrieval of a structured document stored in a structured document storage unit, a structured document index is constructed and stored in the index storage unit. A system is provided. This system analyzes a search expression given from the outside, extracts a search condition, acquires a set of search result candidates that match the search condition, and is stored in the structured document storage means. For each element included in the structured document, search history acquisition means for acquiring a history of search conditions extracted by the search expression processing means applied to the element, and a structure to be indexed For each element included in the document, an index type determining unit that determines an index type based on the most frequently searched type in the history of search conditions applied to the element acquired by the search history acquiring unit; Based on the index type determined for each element by the index type determination unit, an index of the determined index type corresponding to the element is constructed and stored in the index storage unit. And a pull construction means.

上記したように、個々の要素に対して過去に適用された検索条件の履歴から、その検索条件を処理するのに適した索引種別を要素毎に選択して、その索引種別の索引を構築する構成とすることで、検索性能の向上を図ることができる。ここでは、例えば、完全一致型の検索条件の適用が多い場合は完全一致型の検索条件の処理に適したB木索引を選択的に構築し、部分一致型の検索条件の適用が多い場合には部分一致型の検索条件の処理に適したNグラム索引、或は形態素解析による単語索引といった全文検索用索引を選択的に構築すると良い。   As described above, an index type suitable for processing the search condition is selected for each element from the history of search conditions applied to individual elements in the past, and an index of the index type is constructed. With the configuration, the search performance can be improved. Here, for example, when exact match type search conditions are frequently applied, a B-tree index suitable for processing of complete match type search conditions is selectively constructed, and when partial match type search conditions are frequently applied. Is preferably constructed by selectively constructing an N-gram index suitable for partially matching type search condition processing or a full-text search index such as a word index by morphological analysis.

また、要素の名前から、その要素に対して適用される可能性の高い検索条件が推定可能であることに着目し、その推定される検索条件を処理するのに適した索引種別を要素毎に選択して、その索引種別の索引を構築する構成とすることでも、検索性能の向上を図ることができる。例えば、「日付」の要素名を持つ要素の値には完全一致型または大小比較型の検索条件の指定が予測されるためB木索引を選択的に構築し、「本文」の要素名を持つ要素の値には部分一致型の検索条件の指定が予想されるためNグラム索引や形態素解析による単語索引といった全文検索用索引を選択的に構築すると良い。   Also, focusing on the fact that it is possible to estimate search conditions that are highly likely to be applied to the element from the name of the element, an index type suitable for processing the estimated search condition is determined for each element. Search performance can also be improved by selecting and configuring an index of that index type. For example, a B-tree index is selectively constructed with an element name of “body” because the specification of a search condition of an exact match type or a size comparison type is predicted for an element value having an element name of “date”. Since partial match type search conditions are expected to be specified for element values, it is preferable to selectively construct an index for full text search such as an N-gram index or a word index based on morphological analysis.

また、構造化文書の構造(スキーマ)の指定の一部としてデータ型が与えられている場合は、要素の値のデータ型に応じて、そのデータ型を処理するのに適した索引種別の索引を構築する構成とすることでも、検索性能の向上を図ることができる。ここでは、例えば、数値型であれば数値型B木索引を選択的に構築し、バイナリ型であれば索引を構築しないことを選択し、文字列型であれば全文検索用索引を選択的に構築すると良い。   In addition, if a data type is given as part of the structure (schema) specification of a structured document, an index of an index type suitable for processing the data type according to the data type of the element value Even with the configuration of constructing, the search performance can be improved. Here, for example, a numerical type B-tree index is selectively constructed for a numeric type, an index is not constructed for a binary type, and a full-text search index is selectively constructed for a character string type. It is good to build.

本発明によれば、検索に要求される厳密性は要素に依存することに着目し、要素毎に、その要素に適した種別の索引を構築することにより、良好な更新検索性能を維持しながら検索の厳密性を維持することができる。   According to the present invention, attention is paid to the fact that the strictness required for the search depends on the element, and by building an index of a type suitable for the element for each element, while maintaining good update search performance The strictness of search can be maintained.

以下、本発明の一実施形態につき図面を参照して説明する。
図1は本発明の一実施形態に係る情報検索システムの構成を示すブロック図である。この情報検索システムは、主として、データベース管理システム(Data Base Management System:DBMS)10と、構造化文書データベース(構造化文書DB)21と、Nグラム索引データベース(Nグラム索引DB)22と、単語索引データベース(単語索引DB)23と、B木(B*Tree)索引データベース(B木索引DB)24と、設定ファイル25と、索引種別辞書26と、ログファイル27とを備えている。構造化文書DB21と、Nグラム索引DB22、単語索引DB23及びB木索引DB24の各索引DBと、設定ファイル25と、索引種別辞書26と、ログファイル27とは、DBMS10からアクセス可能なデータ格納手段としての図示せぬディスクドライブ(ディスク)に置かれている。
Hereinafter, an embodiment of the present invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing a configuration of an information search system according to an embodiment of the present invention. This information retrieval system mainly includes a database management system (DBMS) 10, a structured document database (structured document DB) 21, an N-gram index database (N-gram index DB) 22, and a word index. A database (word index DB) 23, a B-tree (B * Tree) index database (B-tree index DB) 24, a setting file 25, an index type dictionary 26, and a log file 27 are provided. The structured document DB 21, the N-gram index DB 22, the word index DB 23, and the B-tree index DB 24, the setting file 25, the index type dictionary 26, and the log file 27 are data storage means accessible from the DBMS 10. Is placed in a disk drive (disk) (not shown).

構造化文書DB21は、少なくとも1つの構造化文書(例えば、複数の構造化文書)の文書データを格納するのに用いられる。Nグラム索引DB22は、Nグラム索引技術(Nグラム索引方式)で作成された索引レコード(Nグラム索引)を格納するのに用いられ、単語索引DB23は、形態素解析索引技術(形態素解析索引方式)で作成された索引レコード(単語索引)を格納するのに用いられる。B木索引DB24は、キーの値とデータ自身との関係を保持する索引レコードに、索引レコードを効率的に検索するための階層的なインデックスレコード情報を付与することでB木を構成し、格納するのに用いられる。   The structured document DB 21 is used to store document data of at least one structured document (for example, a plurality of structured documents). The N-gram index DB 22 is used to store index records (N-gram index) created by the N-gram index technique (N-gram index system), and the word index DB 23 is a morpheme analysis index technique (morpheme analysis index system). Used to store the index record (word index) created in The B-tree index DB 24 configures and stores a B-tree by adding hierarchical index record information for efficiently searching the index record to the index record that holds the relationship between the key value and the data itself. Used to do.

設定ファイル25は、各要素の値の長さ(値長)から、その値の検索に適した索引の種別を決定するのに必要な文字列長閾値を予め設定しておくのに用いられる。索引種別辞書26は、構造化文書に含まれる各要素について、その要素の値を検索するのに適した索引種別(つまり索引方式)を設定するのに用いられる。ここでは、索引種別辞書26は、各要素の名前毎に、その名前(要素名)と、その要素名の要素の値を検索するのに適した索引種別とを組にして保持するのに用いられる。つまり索引種別辞書26は、各要素の要素名に対応付けて、その要素名の要素の値を検索するのに適した索引種別を保持するのに用いられる。ログファイル27は、構造化文書DB21に格納された構造化文書に含まれている、各要素の値をログ情報として蓄積するのに用いられる。なお、ログファイル27に、各要素の値の長さ(値長)がログ情報として蓄積される構成であっても構わない。   The setting file 25 is used to set in advance a character string length threshold necessary for determining an index type suitable for searching for a value from the length (value length) of each element. The index type dictionary 26 is used to set an index type (that is, an index method) suitable for searching the value of each element included in the structured document. Here, for each element name, the index type dictionary 26 is used to hold the name (element name) and an index type suitable for searching the element value of the element name as a set. It is done. In other words, the index type dictionary 26 is used to hold an index type suitable for searching for the value of an element of the element name in association with the element name of each element. The log file 27 is used to accumulate each element value included in the structured document stored in the structured document DB 21 as log information. The log file 27 may be configured such that the length of the value of each element (value length) is accumulated as log information.

DBMS10は、構造化文書DB21、Nグラム索引DB22、単語索引DB23及びB木索引DB24の各DB(データベース)を管理する構造化文書管理システムである。DBMS10は、アクセス処理部11と、構造化文書管理部12と、検索エンジン13とから構成される。DBMS10は、計算機システムにインストールされたデータベース管理のためのソフトウェアプログラム(データベース管理プログラム)を当該計算機システム(内のCPU)が読み取って実行することにより実現される。このプログラムは、コンピュータで読み取り可能な記憶媒体(フロッピー(登録商標)ディスクに代表される磁気ディスク、CD−ROM、DVDに代表される光ディスク、フラッシュメモリに代表される半導体メモリ等)に予め格納して頒布可能である。また、このプログラムが、ネットワークを介してダウンロード(頒布)されても構わない。   The DBMS 10 is a structured document management system that manages each of the structured document DB 21, the N-gram index DB 22, the word index DB 23, and the B-tree index DB 24 (database). The DBMS 10 includes an access processing unit 11, a structured document management unit 12, and a search engine 13. The DBMS 10 is realized by reading and executing a software program (database management program) for database management installed in the computer system by the computer system (CPU in the computer system). This program is stored in advance in a computer-readable storage medium (a magnetic disk typified by a floppy (registered trademark) disk, a CD-ROM, an optical disk typified by a DVD, a semiconductor memory typified by a flash memory, etc.). Can be distributed. Further, this program may be downloaded (distributed) via a network.

アクセス処理部11は、図1の情報検索システムを利用するクライアント(クライアント端末)からの種々のDBアクセス要求を処理する。このクライアントが、図1の情報検索システムを実現する計算機の端末、または当該計算機とネットワークを介して接続された端末のいずれであっても構わない。アクセス処理部11は、アプリケーション30からの更新要求を受け付けて構造化文書管理部12に対して当該更新要求の示す更新処理(データ更新及び索引更新)を行わせる。ここでのデータ更新及び索引更新は、それぞれ新規データの格納及び索引の構築(作成)を含むものとする。また以降の説明では、索引の更新(再構築)を索引の構築で代表させることもある。アクセス処理部11はまた、アプリケーション30からの検索要求を受け付けて、検索エンジン13に対して当該検索要求の示す情報検索を行わせる。   The access processing unit 11 processes various DB access requests from clients (client terminals) that use the information search system of FIG. This client may be either a computer terminal that implements the information search system of FIG. 1 or a terminal connected to the computer via a network. The access processing unit 11 receives an update request from the application 30 and causes the structured document management unit 12 to perform update processing (data update and index update) indicated by the update request. The data update and index update here include storage of new data and construction (creation) of an index, respectively. In the following description, index update (reconstruction) may be represented by index construction. The access processing unit 11 also receives a search request from the application 30 and causes the search engine 13 to perform information search indicated by the search request.

構造化文書管理部12は、データ更新部14と索引管理部15とから構成される。データ更新部14は、アプリケーション30からの更新要求に応じて、構造化文書DB21を対象とする更新処理を行う。索引管理部15は、アプリケーション30からの更新要求に応じて、Nグラム索引DB22、単語索引DB23またはB木索引DB24に格納すべき索引の構築を管理する。この索引の構築には、説明の煩雑さを避けるため、Nグラム索引DB22、単語索引DB23またはB木索引DB24に格納されている索引の更新(再構築)の概念も含まれているものとする。索引管理部15は、Nグラム索引DB22、単語索引DB23またはB木索引DB24のいずれを対象とする索引の構築を行うかを、設定ファイル25、索引種別辞書26またはログファイル27の内容に基づいて決定する。   The structured document management unit 12 includes a data update unit 14 and an index management unit 15. In response to an update request from the application 30, the data update unit 14 performs an update process for the structured document DB 21. The index management unit 15 manages the construction of an index to be stored in the N-gram index DB 22, the word index DB 23, or the B-tree index DB 24 in response to an update request from the application 30. The construction of this index includes the concept of updating (rebuilding) the index stored in the N-gram index DB 22, the word index DB 23, or the B-tree index DB 24 in order to avoid complicated explanation. . The index management unit 15 determines which of the N-gram index DB 22, the word index DB 23, or the B-tree index DB 24 is to be constructed based on the contents of the setting file 25, index type dictionary 26, or log file 27. decide.

検索エンジン13は、データ検索部16と索引参照部17とから構成される。データ検索部16は、アプリケーション30からの検索要求に応じて、構造化文書DB21から検索要求に合致した構造化文書または構造化文書中の要素の値を検索する。このときデータ検索部16は、検索条件を索引参照部17に渡すことにより、その検索条件に合致した構造化文書または構造化文書中の要素の位置の集合(検索結果の候補の集合)を当該索引参照部17から受け取る。   The search engine 13 includes a data search unit 16 and an index reference unit 17. In response to a search request from the application 30, the data search unit 16 searches the structured document DB 21 for a structured document that matches the search request or the value of an element in the structured document. At this time, the data search unit 16 passes the search condition to the index reference unit 17, thereby obtaining a structured document that matches the search condition or a set of element positions in the structured document (a set of search result candidates). Received from the index reference unit 17.

図2は、図1中の構造化文書管理部12の構成を、各DB21〜24等と関連付けて示すブロック図である。構造化文書管理部12は前記したように、データ更新部14と索引管理部15とから構成される。索引管理部15は、文字列長閾値決定部151と、値抽出部152と、索引構築制御部153と、索引構築部154とから構成される。   FIG. 2 is a block diagram showing the structure of the structured document management unit 12 in FIG. 1 in association with the DBs 21 to 24 and the like. As described above, the structured document management unit 12 includes the data update unit 14 and the index management unit 15. The index management unit 15 includes a character string length threshold value determination unit 151, a value extraction unit 152, an index construction control unit 153, and an index construction unit 154.

文字列長閾値決定部151は、データ更新部14によるデータ更新の対象となる文書(部分文書)中の要素の値の長さ(値長)から、その値の検索に適した索引の種別を決定するのに必要な文字列長閾値を決定する。文字列長閾値決定部151は、第1の閾値決定モードでは、設定ファイル25に設定されている文字列長閾値をそのまま目的の文字列長閾値として決定する。また文字列長閾値決定部151は、第2の閾値決定モードでは、構造化文書DB21に格納されている各構造化文書に含まれる各要素の値長の統計情報(分布)から、文字列長閾値を決定する。各要素の値長の情報は、ログファイル27に蓄積されている。   The character string length threshold value determination unit 151 selects an index type suitable for the search of the value from the length (value length) of the element in the document (partial document) to be updated by the data update unit 14. A character string length threshold necessary for the determination is determined. In the first threshold value determination mode, the character string length threshold value determination unit 151 determines the character string length threshold value set in the setting file 25 as a target character string length threshold value as it is. In the second threshold value determination mode, the character string length threshold determination unit 151 determines the character string length from the statistical information (distribution) of the value length of each element included in each structured document stored in the structured document DB 21. Determine the threshold. Information on the value length of each element is accumulated in the log file 27.

値抽出部152は、データ更新部14によるデータ更新の対象となる文書(部分文書)中の要素の値と、当該文書中の位置とを抽出する。索引構築制御部153は、第1の索引種別決定モードでは、値抽出部152によって抽出された要素の値の長さと、文字列長閾値決定部151によって決定された文字列長閾値とから、その値の検索に適した索引の種別(索引方式)を決定する。この第1の索引種別決定モードでは、索引構築時に、過去にログ情報に蓄積した各要素の値長の統計と閾値によって、格納される構造化文書の構造(スキーマ)の各要素に対して今後構築する索引の種別を予め決定しても良い。索引構築制御部153はまた、第2の索引種別決定モードでは、値抽出部152によって抽出された要素の名前と、索引種別辞書26とをもとに、その名前(要素名)の要素に適した索引の種別(索引方式)を決定する。索引構築制御部153は、索引構築部154を制御して、上記抽出された要素の値の検索に適した種別の索引を構築させる。索引構築制御部153は、索引の構築時には、対応する要素の値をログ情報としてログファイル27に蓄積する。   The value extraction unit 152 extracts the value of the element in the document (partial document) that is the target of data update by the data update unit 14 and the position in the document. In the first index type determination mode, the index construction control unit 153 determines the value of the element value extracted by the value extraction unit 152 and the character string length threshold value determined by the character string length threshold value determination unit 151. Determine the index type (index method) suitable for value retrieval. In the first index type determination mode, at the time of building an index, each element of the structure (schema) of the structured document to be stored will be determined based on the statistics and threshold values of the value length of each element accumulated in the log information in the past. The type of index to be constructed may be determined in advance. Further, in the second index type determination mode, the index construction control unit 153 is suitable for the element of the name (element name) based on the name of the element extracted by the value extraction unit 152 and the index type dictionary 26. The index type (index method) is determined. The index construction control unit 153 controls the index construction unit 154 to construct an index of a type suitable for searching for the extracted element value. The index construction control unit 153 accumulates corresponding element values in the log file 27 as log information when constructing the index.

索引構築部154は、グラム(Gram)分割部155と、Nグラム索引更新部156と、形態素解析部157と、単語索引更新部158と、B木索引更新部159とを含む。グラム分割部155は、索引構築制御部153から要素の値と位置の情報を受けて、その値をNグラムに分割してグラム列を作成する。Nグラム索引更新部156は、作成されたグラム列と位置の情報とから、Nグラム索引DB22を対象としてNグラム索引を構築する。形態素解析部157は、索引構築制御部153から要素の値と位置の情報を受けて、その値(文字列)を形態素解析して単語を抽出する。単語索引更新部158は、抽出された単語と位置の情報とから、単語索引DB23を対象として単語索引を構築する。B木索引更新部159は、索引構築制御部153から要素の値と位置の情報を受けて、B木索引DB24を対象としてB木索引を構築する。   Index construction unit 154 includes a gram division unit 155, an N-gram index update unit 156, a morpheme analysis unit 157, a word index update unit 158, and a B-tree index update unit 159. The gram dividing unit 155 receives element value and position information from the index construction control unit 153 and divides the value into N gram to create a gram string. The N-gram index update unit 156 constructs an N-gram index for the N-gram index DB 22 from the created gram string and position information. The morpheme analysis unit 157 receives element value and position information from the index construction control unit 153, and morphologically analyzes the value (character string) to extract words. The word index update unit 158 constructs a word index for the word index DB 23 from the extracted words and position information. The B-tree index update unit 159 receives element value and position information from the index construction control unit 153 and constructs a B-tree index for the B-tree index DB 24.

図3は、図1中の検索エンジン13の構成を、各DB21〜24等と関連付けて示すブロック図である。検索エンジン13は前記したように、データ検索部16と索引参照部17とから構成される。   FIG. 3 is a block diagram showing the configuration of the search engine 13 in FIG. 1 in association with the DBs 21 to 24 and the like. As described above, the search engine 13 includes the data search unit 16 and the index reference unit 17.

データ検索部16は、検索式処理部161とデータ参照部162とを含む。検索式処理部161は、アプリケーション30からの検索要求の示す検索式を解析して、検索に必要な条件(つまり検索条件)を抽出し、その検索条件に合致する検索結果の候補の集合(構造化文書または構造化文書中の要素の位置の集合)を取得する。検索式処理部161はまた、検索結果の候補をデータ参照部162により構造化文書DB21から参照させる。   The data search unit 16 includes a search formula processing unit 161 and a data reference unit 162. The search expression processing unit 161 analyzes the search expression indicated by the search request from the application 30, extracts a condition (that is, search condition) necessary for the search, and sets a search result candidate (structure) that matches the search condition. A set of element positions in the structured document or structured document). The search expression processing unit 161 also causes the data reference unit 162 to refer to search result candidates from the structured document DB 21.

索引参照部17は、索引管理部15中の文字列長閾値決定部151と同様の文字列長閾値決定部171と、索引参照制御部172と、グラム分割部173と、Nグラム索引検索部174と、形態素解析部175と、単語索引検索部176と、B木索引検索部177とを含む。索引参照制御部172は、検索式処理部161から与えられる検索条件に含まれている文字列の長さと文字列長閾値決定部171によって決定される文字列長閾値とから、参照すべき索引の種別を判別する。索引参照制御部172は、判別された索引種別に対応する、グラム分割部173、形態素解析部175またはB木索引検索部177に検索条件を渡して、対応する索引を参照させる。グラム分割部173は、検索条件に含まれる文字列をNグラムに分割してグラム列を作成する。Nグラム索引検索部174は、作成されたグラム列に対応するNグラム索引レコードをNグラム索引DB22から検索し、その位置の情報を索引参照制御部172に返す。形態素解析部175は、検索条件に含まれる文字列を形態素解析して単語を抽出する。単語索引検索部176は、抽出された単語に対応する単語索引レコードを単語索引DB23から検索し、その位置の情報を索引参照制御部172に返す。B木索引検索部177は、検索条件に含まれる文字列に対応するB木索引レコードをB木索引DB24から検索し、その位置の情報を索引参照制御部172に返す。   The index reference unit 17 includes a character string length threshold value determination unit 171 similar to the character string length threshold value determination unit 151 in the index management unit 15, an index reference control unit 172, a gram division unit 173, and an N-gram index search unit 174. A morpheme analysis unit 175, a word index search unit 176, and a B-tree index search unit 177. The index reference control unit 172 uses the character string length included in the search condition given from the search expression processing unit 161 and the character string length threshold value determined by the character string length threshold value determination unit 171 to determine the index to be referred to. Determine the type. The index reference control unit 172 passes the search condition to the gram division unit 173, the morpheme analysis unit 175, or the B-tree index search unit 177 corresponding to the determined index type, and refers to the corresponding index. The gram dividing unit 173 divides a character string included in the search condition into N gram to create a gram string. The N-gram index search unit 174 searches the N-gram index DB 22 for an N-gram index record corresponding to the created gram string, and returns the position information to the index reference control unit 172. The morphological analysis unit 175 extracts words by performing morphological analysis on the character string included in the search condition. The word index search unit 176 searches the word index DB 23 for a word index record corresponding to the extracted word, and returns information on the position to the index reference control unit 172. The B-tree index search unit 177 searches the B-tree index DB 24 for a B-tree index record corresponding to the character string included in the search condition, and returns the position information to the index reference control unit 172.

図4は、図2中の索引構築制御部153の構成を示すブロック図である。この索引構築制御部153は、値長計算部153aと、比較部153bと、索引種別決定部153cとを含む。値長計算部153aは、値抽出部152によって抽出された要素の値の長さ(値長)を算出する。比較部153bは、比較部153bによって算出された値長を文字列長閾値決定部151によって決定された文字列長閾値とを比較する。索引種別決定部153cは、索引種別決定モードに固有の索引種別決定処理を行う。本実施形態では、第1の索引種別決定モードと第2の索引種別決定モードの2種類が用意されている。索引種別決定部153cは、第1の索引種別決定モードの場合、比較部153bの比較結果に応じて、対応する要素の値に適用する索引種別を決定する。また、第2の索引種別決定モードの場合には、索引種別決定部153cは、対応する要素の名前(要素名)で索引種別辞書26を参照することにより、その要素名の要素の値に適用する索引種別を決定する。   FIG. 4 is a block diagram showing the configuration of the index construction control unit 153 in FIG. The index construction control unit 153 includes a value length calculation unit 153a, a comparison unit 153b, and an index type determination unit 153c. The value length calculation unit 153 a calculates the length (value length) of the value of the element extracted by the value extraction unit 152. The comparison unit 153b compares the value length calculated by the comparison unit 153b with the character string length threshold value determined by the character string length threshold value determination unit 151. The index type determination unit 153c performs an index type determination process specific to the index type determination mode. In the present embodiment, two types, a first index type determination mode and a second index type determination mode, are prepared. In the first index type determination mode, the index type determination unit 153c determines the index type to be applied to the corresponding element value according to the comparison result of the comparison unit 153b. In the case of the second index type determination mode, the index type determination unit 153c refers to the index type dictionary 26 by the name of the corresponding element (element name), and applies it to the element value of the element name. The index type to be determined is determined.

次に、図1の情報検索システムにおける索引更新処理について、索引管理部15の動作を中心に、図5のフローチャートを参照して説明する。まず、ユーザの操作に従って、クライアント端末上のアプリケーション30から図1の情報検索システムに対して、データ追加、或はデータの上書き等の更新要求が送られたものとする。この更新要求は、DBMS10内のアクセス処理部11で受け付けられる。するとアクセス処理部11は、アプリケーション30からの更新要求を構造化文書管理部12内のデータ更新部14に通知する。   Next, index update processing in the information search system of FIG. 1 will be described with reference to the flowchart of FIG. First, it is assumed that an update request for adding data or overwriting data is sent from the application 30 on the client terminal to the information search system of FIG. This update request is accepted by the access processing unit 11 in the DBMS 10. Then, the access processing unit 11 notifies the update request from the application 30 to the data update unit 14 in the structured document management unit 12.

データ更新部14は、通知された更新要求に従い、当該更新要求で指定されるデータ(文書データ)を構造化文書DB21に新たに格納する処理、或は当該更新要求で指定されるデータ(文書データまたは部分文書データ)で構造化文書DB21の対応するデータを更新する処理を行う。同時にデータ更新部14は、そのデータ(文書データまたは部分文書データ)を構造化文書DB21内の格納位置の情報と共に索引管理部15内の値抽出部152へ渡す。   In accordance with the notified update request, the data update unit 14 newly stores data (document data) specified by the update request in the structured document DB 21 or data (document data) specified by the update request. Alternatively, the corresponding data in the structured document DB 21 is updated with the partial document data). At the same time, the data update unit 14 passes the data (document data or partial document data) to the value extraction unit 152 in the index management unit 15 together with the storage position information in the structured document DB 21.

値抽出部152は、データ更新部14から渡されたデータから索引を付与すべき構造化文書の要素値を全て抽出する。この要素値の抽出には、構造化文書がXMLであれば、例えばXMLパーサを使用できる。値抽出部152は、データ更新部14から渡されたデータから抽出された全ての要素値を、構造化文書DB21内の格納位置の情報と共に索引構築制御部153へ渡す。   The value extraction unit 152 extracts all element values of the structured document to be indexed from the data passed from the data update unit 14. For extracting the element value, if the structured document is XML, for example, an XML parser can be used. The value extraction unit 152 passes all the element values extracted from the data passed from the data update unit 14 to the index construction control unit 153 together with the storage position information in the structured document DB 21.

索引構築制御部153は、索引種別モードを判定する(ステップS1)。もし、索引種別モードとして第1の索引種別モードが指定されているならば、索引構築制御部153は文字列長閾値決定部151に対して文字列長閾値を決定することを要求する。すると文字列長閾値決定部151は、閾値決定モードを判定する(ステップS2)。   The index construction control unit 153 determines the index type mode (step S1). If the first index type mode is designated as the index type mode, the index construction control unit 153 requests the character string length threshold value determining unit 151 to determine the character string length threshold value. Then, the character string length threshold value determination unit 151 determines the threshold value determination mode (step S2).

もし、閾値決定モードとして第1の閾値決定モードが指定されているならば、文字列長閾値決定部151は、設定ファイル25に設定されている文字列長閾値を読み込んで、その閾値を索引構築制御部153が使用する文字列長閾値として決定する(ステップS3)。これに対し、閾値決定モードとして第2の閾値決定モードが指定されているならば、文字列長閾値決定部151は、ログファイル27に保存されているログ情報から、構造化文書DB21に格納された構造化文書に含まれている、各要素の値長の分布(統計情報)を算出する(ステップS4)。そして文字列長閾値決定部151は、各要素の値長の分布から、索引構築制御部153が使用する文字列長閾値を決定する(ステップS5)。このように第2の閾値決定モードでは、構造化文書DB21に格納された構造化文書に含まれている各要素に適した文字列長閾値が動的に決定される。本実施形態では、上記分布において、要素数を2等分する値長が文字列長閾値として決定される。しかし、文字列長閾値の決定の仕方は、これに限るものではない。   If the first threshold value determination mode is designated as the threshold value determination mode, the character string length threshold value determination unit 151 reads the character string length threshold value set in the setting file 25 and builds the threshold value as an index. It determines as a character string length threshold value which the control part 153 uses (step S3). On the other hand, if the second threshold determination mode is designated as the threshold determination mode, the character string length threshold determination unit 151 stores the log information stored in the log file 27 in the structured document DB 21. The distribution (statistical information) of the value length of each element included in the structured document is calculated (step S4). Then, the character string length threshold determining unit 151 determines the character string length threshold used by the index construction control unit 153 from the distribution of the value lengths of the elements (step S5). Thus, in the second threshold value determination mode, the character string length threshold value suitable for each element included in the structured document stored in the structured document DB 21 is dynamically determined. In the present embodiment, in the above distribution, a value length that bisects the number of elements is determined as a character string length threshold. However, the method of determining the character string length threshold is not limited to this.

閾値決定モードは、アクセス処理部11からの問い合わせに従うユーザの操作に応じて、アプリケーション30から指定可能である。また、索引種別モードも、ユーザの操作に応じて、アプリケーション30から指定可能である。更に、閾値決定モード、或は索引種別モードを、データベースの属性として予め保持することも可能である。本実施形態では、索引種別モードとして第1の索引種別モードが指定された場合に、閾値決定モードが有効となる。   The threshold value determination mode can be designated from the application 30 in accordance with a user operation in accordance with an inquiry from the access processing unit 11. The index type mode can also be specified from the application 30 according to the user's operation. Furthermore, the threshold determination mode or the index type mode can be held in advance as a database attribute. In the present embodiment, when the first index type mode is designated as the index type mode, the threshold value determination mode is valid.

文字列長閾値決定部151によって決定された文字列長閾値は、索引構築制御部153へ渡される。索引構築制御部153内の値長計算部153aは、値抽出部152によって抽出された各要素の値毎に、その値の長さ、即ち値長を算出する。索引構築制御部153内の比較部153bは、値長計算部153aによって算出された各要素の値長毎に、その値長を文字列長閾値決定部171によって決定された文字列長閾値と比較する。そして比較部153bは、各要素の値長毎の比較結果を索引構築制御部153内の索引種別決定部153cへ渡す。なお、値長計算部153a及び比較部153bが、第1の索引種別モードが指定されている場合だけ動作する構成であっても構わない。   The character string length threshold value determined by the character string length threshold value determination unit 151 is passed to the index construction control unit 153. The value length calculation unit 153a in the index construction control unit 153 calculates the length of the value, that is, the value length, for each element value extracted by the value extraction unit 152. The comparison unit 153b in the index construction control unit 153 compares the value length of each element calculated by the value length calculation unit 153a with the character string length threshold value determined by the character string length threshold value determination unit 171. To do. Then, the comparison unit 153b passes the comparison result for each value length of each element to the index type determination unit 153c in the index construction control unit 153. The value length calculation unit 153a and the comparison unit 153b may be configured to operate only when the first index type mode is designated.

索引種別決定部153cは、第1の索引種別モードが指定されている場合、比較部153bの比較結果に応じて、値抽出部152によって抽出された各要素の値毎に、その値に最適な索引種別を決定する。ここでは索引種別決定部153cは、要素の値の長さが文字列長閾値を超えているならば(ステップS6)、その値に最適な索引種別として単語索引を決定する(ステップS7)。この場合、索引種別決定部153cは、対応する要素の値と構造化文書DB21内の格納位置の情報との組を、形態素解析部157へ渡す(ステップS8)。これに対し、要素の値の長さが文字列長閾値以下であるならば(ステップS6)、索引種別決定部153cは、その値に最適な索引種別としてNグラム索引を決定する(ステップS9)。この場合、索引種別決定部153cは、対応する要素の値と構造化文書DB21内の格納位置の情報との組をグラム分割部155へ渡す(ステップS10)。   When the first index type mode is designated, the index type determination unit 153c is optimal for the value of each element extracted by the value extraction unit 152 according to the comparison result of the comparison unit 153b. Determine the index type. Here, if the length of the element value exceeds the character string length threshold (step S6), the index type determination unit 153c determines the word index as the optimal index type for the value (step S7). In this case, the index type determination unit 153c passes the set of the value of the corresponding element and the storage position information in the structured document DB 21 to the morpheme analysis unit 157 (step S8). On the other hand, if the length of the element value is equal to or smaller than the character string length threshold (step S6), the index type determination unit 153c determines the N-gram index as the optimal index type for the value (step S9). . In this case, the index type determination unit 153c passes the set of the value of the corresponding element and the storage position information in the structured document DB 21 to the gram dividing unit 155 (step S10).

グラム分割部155は、索引種別決定部153cから要素の値(文字列)と格納位置の情報を渡された場合、当該要素の値(文字列)をNグラム(長さNの語彙)に分割してグラム列(Nグラムの集合)を作成する。グラム分割部155は、作成されたグラム列と格納位置の情報をNグラム索引更新部156へ渡す。Nグラム索引更新部156は、グラム列を構成する各グラムを、それぞれ格納位置の情報と組にして、それぞれNグラム索引(Nグラム索引レコード)として、Nグラム索引DB22に登録またはNグラム索引DB22内の対応する索引レコードを追加する。即ちNグラム索引更新部156は、Nグラム索引DB22を対象としてNグラム索引を構築する。   The gram dividing unit 155 divides the element value (character string) into N gram (length N vocabulary) when the element value (character string) and the storage position information are passed from the index type determination unit 153c. Thus, a gram sequence (a set of N-grams) is created. The gram dividing unit 155 passes the created gram string and storage location information to the N-gram index updating unit 156. The N-gram index update unit 156 registers each gram constituting the gram string together with the storage location information, and registers the gram as an N-gram index (N-gram index record) in the N-gram index DB 22 or the N-gram index DB 22 Add the corresponding index record in That is, the N-gram index update unit 156 builds an N-gram index for the N-gram index DB 22.

一方、形態素解析部157は、索引種別決定部153cから要素の値(文字列)と格納位置の情報を渡された場合、当該要素の値(文字列)を形態素解析して単語を抽出する。形態素解析部157は、抽出された単語の集合(単語集合)と格納位置の情報を単語索引更新部158へ渡す。単語索引更新部158は、単語集合中の各単語を、それぞれ格納位置の情報と組にして、それぞれ単語索引(単語索引レコード)として、単語索引DB23に登録または当該単語索引DB23内の対応する索引レコードを追加する。即ち単語索引更新部158は、単語索引DB23を対象として単語索引を構築する。   On the other hand, when the element value (character string) and the storage position information are passed from the index type determination unit 153c, the morpheme analysis unit 157 extracts words by performing morphological analysis on the value (character string) of the element. The morpheme analysis unit 157 passes the extracted word set (word set) and storage location information to the word index update unit 158. The word index update unit 158 registers each word in the word set together with the storage location information, and registers each word as a word index (word index record) in the word index DB 23 or a corresponding index in the word index DB 23. Add a record. In other words, the word index update unit 158 constructs a word index for the word index DB 23.

上記したように本実施形態においては、図1の情報検索システムの索引種別モードとして第1の索引種別モードが指定されている場合(ステップSS1)、値抽出部152によって抽出された各要素の値毎に、その値の長さに応じて、その長さに最適な索引種別が決定される(ステップS6,S7,S9)。ここでは、値の長さが文字列長閾値以下であるならば、つまり値長が短いならば、その値(文字列)からNグラム索引の集合が生成されて、Nグラム索引DB22を対象とするNグラム索引の構築が行われる。これに対して、値の長さが文字列長閾値を超えているならば、つまり値長が長いならば、その値(文字列)から、単語索引の集合が生成されて、単語索引DB23を対象とする単語索引の構築が行われる。   As described above, in the present embodiment, when the first index type mode is designated as the index type mode of the information search system of FIG. 1 (step SS1), the value of each element extracted by the value extraction unit 152 Each time, the index type most suitable for the length is determined according to the length of the value (steps S6, S7, S9). Here, if the length of the value is equal to or less than the character string length threshold, that is, if the value length is short, a set of N-gram indexes is generated from the value (character string), and the N-gram index DB 22 is targeted. An N-gram index is constructed. On the other hand, if the value length exceeds the character string length threshold value, that is, if the value length is long, a set of word indexes is generated from the value (character string), and the word index DB 23 is The target word index is constructed.

このように本実施形態では、第1の索引種別モードが指定されている場合、値長の短い要素値だけをNグラム索引の構築の対象としている。このため、Nグラム索引の短所である、データ量が膨大となるのを防止しながら、Nグラム索引の長所である厳密な検索に対応できる。また、第1の索引種別モードが指定されている場合、値長の長い要素値は、単語索引の構築の対象としている。このため、値長の長い要素値をNグラム索引の構築の対象とする場合に比べて、データ量が膨大となるのを防止できる。しかも、値長が長い要素値は、一般に厳密な検索や単語にならない文字列での検索が意味を持たない場合が多い。このため、値長が長い要素値を単語索引の構築の対象としても、当該単語索引の短所である、厳密な検索には向かないことによる不具合の発生を防止できる。   As described above, in the present embodiment, when the first index type mode is designated, only an element value having a short value length is set as an N-gram index construction target. Therefore, it is possible to cope with a strict search that is an advantage of the N-gram index while preventing an enormous amount of data, which is a disadvantage of the N-gram index. Further, when the first index type mode is designated, the element value having a long value length is set as a word index construction target. For this reason, it is possible to prevent the amount of data from becoming enormous as compared with the case where an element value having a long value length is set as an N-gram index construction target. Moreover, in general, element values having a long value length are often not meaningful for a strict search or a search using a character string that does not become a word. For this reason, even if an element value having a long value length is set as a word index construction target, it is possible to prevent the occurrence of problems due to the disadvantage of the word index, which is not suitable for strict search.

一方、第2の索引種別モードが指定されている場合(ステップS1)、索引種別決定部153cは、値抽出部152によって抽出された各要素毎に、その要素の名前、つまり要素名をキーにして索引種別辞書26を参照することで(ステップS11)、その要素名に対応して予め定められている索引種別を決定する(ステップS12)。ここで、例えば「日付」の要素名を持つ要素の値には、完全一致型または大小比較型の検索条件の指定が予測(推定)される。この完全一致型または大小比較型の検索条件の処理にはB木索引が適していることが知られている。また、「本文」の要素名を持つ場合は、部分一致型の検索条件の指定が予測される。この部分一致型の検索条件の処理には全文検索用索引、例えばNグラム索引または単語索引(つまり形態素解析による索引)が適していることが知られている。そこで、本実施形態の索引種別辞書26では、「日付」の要素名と組をなす索引種別としてB木索引が用いられ、「本文」の要素名と組をなす索引種別として全文検索用索引、例えばNグラム索引が用いられる。このNグラム索引に代えて、単語索引を用いることも可能である。また、「本文」の要素名と組をなす索引種別としてNグラム索引及び単語索引の2つを用い、上記第1の索引種別モードが指定されている場合と同様に、対応する要素の値長に応じて、当該Nグラム索引及び単語索引の一方が、実際に適用される索引種別として決定される構成とすることも可能である。   On the other hand, when the second index type mode is designated (step S1), the index type determining unit 153c uses the element name, that is, the element name for each element extracted by the value extracting unit 152 as a key. By referring to the index type dictionary 26 (step S11), a predetermined index type corresponding to the element name is determined (step S12). Here, for example, for the value of an element having an element name of “date”, designation of a search condition of complete match type or size comparison type is predicted (estimated). It is known that the B-tree index is suitable for processing this complete match type or large / small comparison type search condition. When the element name “text” is included, the partial match type search condition is predicted to be specified. It is known that a full-text search index, for example, an N-gram index or a word index (that is, an index based on morphological analysis) is suitable for the processing of this partial match type search condition. Therefore, in the index type dictionary 26 of the present embodiment, the B-tree index is used as an index type that forms a pair with the “date” element name, and a full-text search index as an index type that forms a pair with the “body” element name. For example, an N-gram index is used. A word index can be used instead of the N-gram index. In addition, as in the case where the first index type mode is specified using the N-gram index and the word index as the index type paired with the element name of “text”, the value length of the corresponding element Accordingly, it is possible to adopt a configuration in which one of the N-gram index and the word index is determined as an index type to be actually applied.

索引種別決定部153cは、上記ステップS12で決定された索引種別がB木索引の場合(ステップS13)、対応する要素の値と構造化文書DB21内の格納位置の情報との組をB木索引更新部159へ渡す(ステップS14)。B木索引更新部159は、この要素の値と位置の情報を受けて、B木索引DB24を対象としてB木索引を構築する。また索引種別決定部153cは、対応する要素の値と上記格納位置の情報との組を、ステップS12で決定された索引種別が単語索引であれば形態素解析部157へ渡し(ステップS8)、Nグラム索引であればグラム分割部155へ渡す(ステップS10)。   When the index type determined in step S12 is a B-tree index (step S13), the index type determination unit 153c determines a set of a corresponding element value and storage location information in the structured document DB 21 as a B-tree index. It passes to the update part 159 (step S14). The B-tree index update unit 159 receives information on the value and position of this element, and builds a B-tree index for the B-tree index DB 24 as a target. Also, the index type determination unit 153c passes the set of the corresponding element value and the information on the storage position to the morpheme analysis unit 157 if the index type determined in step S12 is a word index (step S8). If it is a gram index, it is passed to the gram dividing unit 155 (step S10).

ところで、形態素解析部157が要素の値(文字列)を形態素解析した結果に、例えば「東京都」と「東」「京都」のように、2通り(複数通り)の解釈を持つ表記が含まれることがある。この場合、索引構築部154では、検索の漏れを防ぎ検索精度の劣化を防止するために、単語索引に代えて、Nグラム索引を構築するようにしても構わない。これに対し、形態素解析結果に1通りの解釈を持つ表記しか含まれない場合には、そのまま形態素解析を利用した単語索引を構築すればよい。   By the way, the result of the morphological analysis of the element value (character string) by the morpheme analysis unit 157 includes notations having two (multiple) interpretations such as “Tokyo”, “East”, and “Kyoto”. May be. In this case, the index construction unit 154 may construct an N-gram index instead of the word index in order to prevent omission of search and prevent deterioration of search accuracy. On the other hand, if the morphological analysis result includes only a notation having one interpretation, a word index using morphological analysis may be constructed as it is.

この他、上述の「東京都」と「東」「京都」のように、2通り(複数通り)の解釈を持つ表記が含まれる場合に、これらの表記「東京都」「東」「京都」の全てを単語索引としても良い。   In addition, when there are notations having two (multiple) interpretations such as “Tokyo”, “East”, and “Kyoto” described above, these notations “Tokyo”, “East”, “Kyoto” All of these may be used as a word index.

また、要素の値(文字列)を形態素解析した結果に、意味は同じであるが表記が異なる単語が含まれている場合(例えば「呼び出し」と「呼びだし」など)には、いずれかの表記に統一して、単語索引とすると良い。この場合、検索処理時にも、検索対象の単語の表記を統一してから検索すれば良い。   Also, if the result of morphological analysis of the element value (character string) includes words that have the same meaning but different notation (for example, “call” and “call”), either The word index should be unified. In this case, it is only necessary to search after unifying the notation of the words to be searched during the search process.

次に、図1の情報検索システムにおける検索処理について説明する。まず、ユーザの操作に従って、クライアント端末上のアプリケーション30から図1の情報検索システムに対して、データの検索要求が送られたものとする。この検索要求は、DBMS10内のアクセス処理部11で受け付けられる。するとアクセス処理部11は、アプリケーション30からの検索要求を検索エンジン13内のデータ検索部16に通知する。   Next, search processing in the information search system of FIG. 1 will be described. First, it is assumed that a data search request is sent from the application 30 on the client terminal to the information search system of FIG. This search request is accepted by the access processing unit 11 in the DBMS 10. Then, the access processing unit 11 notifies the search request from the application 30 to the data search unit 16 in the search engine 13.

データ検索部16内の検索式処理部161は、通知された検索要求の指定する検索式を解析して要素値に関する検索条件(要素値検索条件)を抽出し、その要素値検索条件となる文字列を索引参照部17内の索引参照制御部172へ渡す。また検索式処理部161は、上記検索式から、要素値以外の検索条件、例えば構造検索条件も抽出する。   The search expression processing unit 161 in the data search unit 16 analyzes the search expression specified by the notified search request, extracts a search condition (element value search condition) regarding the element value, and the character that becomes the element value search condition The column is passed to the index reference control unit 172 in the index reference unit 17. The search formula processing unit 161 also extracts search conditions other than element values, for example, structure search conditions, from the search formula.

一方、索引参照部17内の文字列長閾値決定部171は、索引種別モードとして第1の索引種別モードが指定されている場合、索引管理部15内の文字列長閾値決定部151と同様の手順で文字列長閾値を決定して、その文字列長閾値を索引参照制御部172へ渡す。   On the other hand, the character string length threshold value determination unit 171 in the index reference unit 17 is the same as the character string length threshold value determination unit 151 in the index management unit 15 when the first index type mode is designated as the index type mode. The procedure determines the character string length threshold value and passes the character string length threshold value to the index reference control unit 172.

索引参照制御部172は、索引種別モードとして第1の索引種別モードが指定されている場合、検索式処理部161から渡された、要素値検索条件となる文字列に適合する索引種別を、当該文字列の長さと文字列長閾値決定部171から渡された文字列長閾値とに基づいて決定する。即ち索引参照制御部172は、要素値検索条件となる文字列の長さが閾値を超える場合は形態素解析部175へ当該文字列を与える。これに対して、要素値検索条件となる文字列の長さが閾値を超えない場合には、当該文字列を含む要素の値長は閾値を超えているかも知れないし、或は超えていないかもしれないことから、索引参照制御部172は、グラム分割部173及び形態素解析部175の両方へ当該文字列を与える。   When the first index type mode is designated as the index type mode, the index reference control unit 172 selects the index type that matches the character string that is passed from the search expression processing unit 161 and serves as the element value search condition. This is determined based on the length of the character string and the character string length threshold value passed from the character string length threshold value determination unit 171. That is, the index reference control unit 172 gives the character string to the morpheme analysis unit 175 when the length of the character string serving as the element value search condition exceeds the threshold. On the other hand, if the length of the character string that is the element value search condition does not exceed the threshold value, the value length of the element that includes the character string may or may not exceed the threshold value. Therefore, the index reference control unit 172 gives the character string to both the gram dividing unit 173 and the morpheme analyzing unit 175.

グラム分割部173は、索引更新時のグラム分割部155と同様の動作により、要素値検索条件となる文字列をNグラムに分割してグラム列を生成し、そのグラム列をNグラム索引検索部174へ渡す。形態素解析部175も、索引更新時の形態素解析部157と同様の動作により、要素値検索条件となる文字列から単語を抽出して、抽出された単語の集合を単語索引検索部176へ渡す。   The gram dividing unit 173 generates a gram string by dividing the character string serving as the element value search condition into N-grams by the same operation as the gram dividing unit 155 at the time of updating the index, and the N-gram index searching unit To 174. The morpheme analysis unit 175 also extracts words from the character string serving as the element value search condition by the same operation as the morpheme analysis unit 157 at the time of index update, and passes the extracted word set to the word index search unit 176.

Nグラム索引検索部174は、グラム分割部173から渡された各グラム(語彙)でNグラム索引DB22を検索し、全てのグラム(語彙)を持つ文書の構造化文書DB21内格納位置を求める。つまりNグラム索引検索部174は、各グラム(語彙)の検索で得られる構造化文書DB21内格納位置の集合について、全ての集合からそれぞれ構造化文書DB21内格納位置を選択し入力グラム列の隣接関係を満たすかどうかを検査して、隣接関係を満たした場合は、その先頭のグラムの構造化文書DB21内格納位置を検索結果の集合として保持する。そしてNグラム索引検索部174は、得られた構造化文書DB21内格納位置の集合をNグラム索引検索結果として索引参照制御部172へ返答する。   The N-gram index search unit 174 searches the N-gram index DB 22 with each gram (vocabulary) passed from the gram dividing unit 173, and obtains the storage position in the structured document DB 21 of the document having all the gram (vocabulary). That is, the N-gram index search unit 174 selects the storage position in the structured document DB 21 from all the sets for the set of storage positions in the structured document DB 21 obtained by searching each gram (vocabulary), and adjoins the input gram string. When the relationship is inspected and the adjacency relationship is satisfied, the storage position in the structured document DB 21 of the head gram is held as a set of search results. Then, the N-gram index search unit 174 returns the obtained set of storage positions in the structured document DB 21 to the index reference control unit 172 as an N-gram index search result.

一方、単語索引検索部176は、形態素解析部175から渡された各単語で単語索引DB23を検索し、全ての単語を持つ文書の構造化文書DB21内格納位置を求める。つまり単語索引検索部176は、各単語の検索で得られる構造化文書DB21内格納位置の集合を単語索引検索結果として索引参照制御部172へ返答する。   On the other hand, the word index search unit 176 searches the word index DB 23 with each word passed from the morpheme analysis unit 175, and obtains the storage position in the structured document DB 21 of the document having all the words. That is, the word index search unit 176 returns a set of storage positions in the structured document DB 21 obtained by searching for each word to the index reference control unit 172 as a word index search result.

次に、索引種別モードとして第2の索引種別モードが指定されている場合、索引参照制御部172は、検索式処理部161から渡された、要素値検索条件となる文字列に適合する索引種別を、索引更新時の索引構築制御部153(内の索引種別決定部153c)と同様の動作により、索引種別辞書26に従って決定する。索引参照制御部172は、索引種別としてB木索引を決定した場合、要素値検索条件となる文字列をB木索引検索部177へ渡す。B木索引検索部177は、索引参照制御部172から渡された文字列でB木索引DB24を検索し、B木の木構造のルートノードからリーフノードへ向けて、検索対象キーの大小関係をもとに順次ノードを辿り、リーフノードに到達したらリーフノードに含まれる検索対象キーに対応する構造化文書DB21内格納位置を全て求める。索引種別としてNグラム索引または単語索引が決定された場合の動作は、上記第1の索引種別モードが指定されている場合と同様である。   Next, when the second index type mode is designated as the index type mode, the index reference control unit 172 matches the character string that matches the character string that is passed from the search expression processing unit 161 and serves as the element value search condition. Is determined according to the index type dictionary 26 by the same operation as that of the index construction control unit 153 (the index type determination unit 153c in the index update). When the B-tree index is determined as the index type, the index reference control unit 172 passes a character string serving as an element value search condition to the B-tree index search unit 177. The B-tree index search unit 177 searches the B-tree index DB 24 with the character string passed from the index reference control unit 172, and determines the magnitude relationship of the search target keys from the root node of the B-tree tree structure to the leaf nodes. The nodes are sequentially traced, and when the leaf node is reached, all the storage positions in the structured document DB 21 corresponding to the search target key included in the leaf node are obtained. The operation when the N-gram index or the word index is determined as the index type is the same as that when the first index type mode is specified.

索引参照制御部172は、Nグラム索引検索部174、単語索引検索部176及びB木索引検索部177のうち検索に用いたものから得られた各索引検索結果の集合から、もしそれが複数であればOR演算を行って重複を削除した上で、索引検索結果の候補集合として、構造化文書DB21内格納位置の集合を検索式処理部161に返答する。検索式処理部161は、索引参照制御部172から返された候補集合に基づき、データ参照部162へ構造化文書DB21内の各格納位置の情報を渡す。データ参照部162は、検索式処理部161から渡された構造化文書DB21内の各格納位置の情報に基づいて、それぞれ対応する構造化文書を特定して、当該検索式処理部161に返答する。検索式処理部161は、データ参照部162から返されたそれぞれの構造化文書を対象に、検索式から抽出された要素値以外の検索条件(構造検索条件)に合致しているか、更には指定の要素値が正しく含まれているかを確認する。そして検索式処理部161は、検索式に合致する構造化文書の集合を結果集合として、アクセス処理部11を経由してアプリケーション30に返答する。   The index reference control unit 172 includes a plurality of index search results obtained from the N-gram index search unit 174, the word index search unit 176, and the B-tree index search unit 177 used for the search. If there is, an OR operation is performed to delete the duplication, and a set of storage positions in the structured document DB 21 is returned to the search expression processing unit 161 as a candidate set of index search results. The search expression processing unit 161 passes information on each storage position in the structured document DB 21 to the data reference unit 162 based on the candidate set returned from the index reference control unit 172. The data reference unit 162 identifies the corresponding structured document based on the information of each storage position in the structured document DB 21 delivered from the search formula processing unit 161 and returns the specified structured document to the search formula processing unit 161. . The search formula processing unit 161 targets, for each structured document returned from the data reference unit 162, whether or not it matches a search condition (structure search condition) other than the element value extracted from the search formula. Check if the element value of is correctly included. Then, the search formula processing unit 161 returns a set of structured documents matching the search formula as a result set to the application 30 via the access processing unit 11.

上記実施形態では、幾つかのモードと、そのモードに対応した索引種別決定機能、或は文字列長閾値決定機能とが用意されている。しかし、この種のモードを用意せずに、ある特定の索引種別決定機能、或は文字列長閾値決定機能のみが用意される構成であっても構わない。   In the above embodiment, several modes and an index type determination function or a character string length threshold determination function corresponding to the mode are prepared. However, a configuration in which only a specific index type determination function or a character string length threshold determination function is prepared without preparing this type of mode may be used.

また、上記実施形態では、ログファイル27には、構造化文書DB21に格納された構造化文書に含まれている各要素の値が、索引の構築時に索引構築制御部153によって蓄積される。しかし、特定の種別の検索条件、例えば完全一致型の検索条件に合致した構造化文書に含まれている要素の値のみがログファイル27に蓄積される構成としても良い。この場合、ログファイル27に蓄積された、完全一致型の検索条件に合致した構造化文書に含まれている要素の値の長さに基づいて、文字列長閾値を決定することで、上記実施形態と比べて索引種別の決定に一層適した文字列長閾値を決定できる。なお、完全一致型の検索条件に合致した構造化文書は、検索式処理部161によって確認されるため、当該構造化文書に含まれている要素の値をログファイル27に蓄積する処理は、当該検索式処理部161に行わせると良い。   In the above embodiment, the value of each element included in the structured document stored in the structured document DB 21 is accumulated in the log file 27 by the index construction control unit 153 when the index is constructed. However, only a value of an element included in a structured document that matches a specific type of search condition, for example, a perfect match type search condition may be stored in the log file 27. In this case, the character string length threshold value is determined based on the length of the element value included in the structured document that matches the search condition of the exact match type stored in the log file 27, and the above-described implementation is performed. A character string length threshold more suitable for determining the index type than the form can be determined. Note that a structured document that matches the exact match type search condition is confirmed by the search expression processing unit 161. Therefore, the process of accumulating the element values included in the structured document in the log file 27 The search expression processing unit 161 may be performed.

また、個々の要素に対して適用された検索条件を当該要素に対応付けて、例えば検索式処理部161がログファイル27に蓄積する構成としても良い。この場合、索引構築制御部153内の索引種別決定部153cは、値抽出部152によって抽出された要素に対応付けてログファイル27に蓄積されている検索式の履歴、即ち当該要素に対して過去に適用された検索条件の履歴に基づいて、その要素の値に適した索引種別を決定することが可能となる。例えば、ある要素に対して適用された検索条件として、完全一致型の検索条件が最も多い場合、その完全一致型の検索条件の処理に適したB木索引を、当該要素に適用する索引種別として決定すると良い。また、部分一致型の検索条件が最も多く適用された要素に対しては、部分一致型の検索条件の処理に適した、Nグラム索引または単語索引に代表される全文検索用索引を適用すると良い。これにより、検索性能を向上できる。   Further, the search condition applied to each element may be associated with the element, and the search formula processing unit 161 may accumulate in the log file 27, for example. In this case, the index type determination unit 153c in the index construction control unit 153 matches the element extracted by the value extraction unit 152 with the history of the search formula stored in the log file 27, that is, the past for the element. Based on the history of search conditions applied to the index type, it is possible to determine an index type suitable for the value of the element. For example, when there are most exact match type search conditions as a search condition applied to a certain element, a B-tree index suitable for processing the complete match type search condition is used as an index type to be applied to the element. It is good to decide. In addition, for an element to which a partial match type search condition is applied most, it is preferable to apply a full text search index represented by an N-gram index or a word index suitable for processing a partial match type search condition. . Thereby, search performance can be improved.

さて、要素の値のデータ型によっても、その要素に適した索引の種別は異なる。そこで、構造化文書の構造(スキーマ)の指定の一部としてデータ型が与えられている場合は、要素の値のデータ型に応じて、そのデータ型を処理するのに適した索引の種別が、例えば索引種別決定部153cによって決定される構成とすることでも、検索性能を向上できる。ここでは、例えば数値型であれば数値型のB木索引を、文字列型であれば全文検索用索引を、それぞれ対応する要素に適用すると良い。また、バイナリ型は、対応する要素を索引構築の対象外とすると良い。   Now, the type of index suitable for an element varies depending on the data type of the element value. Therefore, if a data type is given as part of the structure (schema) specification of a structured document, the index type suitable for processing that data type is determined according to the data type of the element value. For example, the search performance can also be improved by adopting a configuration determined by the index type determination unit 153c. Here, for example, a numeric type B-tree index may be applied to the corresponding element if it is a numeric type, and a full-text search index if it is a character string type. In the binary type, the corresponding element is preferably excluded from the index construction target.

また、特定の要素に対する検索条件として、複数の異なる検索条件が適用されることがある。そこで複数の異なる検索条件の各々に適した索引種別を索引種別決定部153cが決定して、その種別の索引を、同一の要素の値に対して索引構築部154によってそれぞれ構築させておき、検索時に検索条件が与えられた場合に、その検索条件の処理に適した索引を索引参照制御部172が選択する構成とすることも可能である。例えば、同一の要素の値に対して適用される検索条件に部分一致型の検索条件と大小比較型の検索条件とが混在するような場合には、全文検索用索引だけでは大小比較を行うことはできないし、B木索引では部分一致検索を行うことはできない。このような場合に、上記要素に対して全文検索用索引とB木索引の両方を構築しておき、部分一致検索の場合には全文検索用索引を、大小比較の場合にはB木索引を、それぞれ選択して使用するならば、両方の検索条件を高速に処理できる。   A plurality of different search conditions may be applied as search conditions for a specific element. Therefore, the index type determination unit 153c determines an index type suitable for each of a plurality of different search conditions, and an index of that type is constructed by the index construction unit 154 for the same element value, respectively. In some cases, when a search condition is given, the index reference control unit 172 selects an index suitable for processing the search condition. For example, when partial match type search conditions and large / small comparison type search conditions are mixed in the search conditions applied to the value of the same element, size comparison should be performed using the full-text search index alone. It is not possible to perform a partial match search with the B-tree index. In such a case, both a full-text search index and a B-tree index are built for the above elements, and a full-text search index is used for partial match search, and a B-tree index is used for large and small comparisons. If each is selected and used, both search conditions can be processed at high speed.

なお、本発明は、上記実施形態そのままに限定されるものではなく、実施段階ではその要旨を逸脱しない範囲で構成要素を変形して具体化できる。また、上記実施形態に開示されている複数の構成要素の適宜な組み合せにより種々の発明を形成できる。例えば、実施形態に示される全構成要素から幾つかの構成要素を削除してもよい。   Note that the present invention is not limited to the above-described embodiment as it is, and can be embodied by modifying the constituent elements without departing from the scope of the invention in the implementation stage. Further, various inventions can be formed by appropriately combining a plurality of constituent elements disclosed in the embodiment. For example, some components may be deleted from all the components shown in the embodiment.

本発明の一実施形態に係る情報検索システムの構成を示すブロック図。1 is a block diagram showing a configuration of an information search system according to an embodiment of the present invention. 図1中の構造化文書管理部12の構成を、各DB21〜24等と関連付けて示すブロック図。The block diagram which shows the structure of the structured document management part 12 in FIG. 1 linked | related with each DB21-24 etc. FIG. 図1中の検索エンジン13の構成を、各DB21〜24等と関連付けて示すブロック図。The block diagram which shows the structure of the search engine 13 in FIG. 1 in association with each DB21-24 etc. FIG. 図2中の索引構築制御部153の構成を示すブロック図。The block diagram which shows the structure of the index construction control part 153 in FIG. 図1の情報検索システムにおける索引更新処理の手順を示すフローチャート。The flowchart which shows the procedure of the index update process in the information search system of FIG.

符号の説明Explanation of symbols

10…データベース管理システム(DBMS、構造化文書管理システム)、12…構造化文書管理部、13…検索エンジン、14…データ更新部、15…索引管理部、16…データ検索部、17…索引参照部、21…構造化文書データベース(構造化文書格納手段)、22…Nグラム索引データベース(索引格納手段)、23…単語索引データベース(索引格納手段)、24…B木索引データベース(索引格納手段)、25…設定ファイル(設定手段)、26…索引種別辞書(索引種別格納手段)、27…ログファイル、151,171…文字列長閾値決定部、152…値抽出部、153…索引構築制御部、153a…値長計算部、153b…比較部、153c…索引種別決定部、154…索引構築部、161…検索式処理部、172…索引参照制御部(索引選択手段)。   DESCRIPTION OF SYMBOLS 10 ... Database management system (DBMS, structured document management system), 12 ... Structured document management part, 13 ... Search engine, 14 ... Data update part, 15 ... Index management part, 16 ... Data search part, 17 ... Index reference , 21 ... structured document database (structured document storage means), 22 ... N-gram index database (index storage means), 23 ... word index database (index storage means), 24 ... B-tree index database (index storage means) 25 ... Setting file (setting means), 26 ... Index type dictionary (index type storage means), 27 ... Log file, 151, 171 ... Character string length threshold value determination unit, 152 ... Value extraction unit, 153 ... Index construction control unit , 153a: Value length calculation unit, 153b ... Comparison unit, 153c ... Index type determination unit, 154 ... Index construction unit, 161 ... Search formula processing unit, 172 ... Index Irradiation control unit (index selection means).

Claims (7)

構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納する構造化文書管理システムにおいて、
外部から与えられる検索式を解析して検索条件を抽出し、その検索条件に合致する検索結果の候補の集合を取得する検索式処理手段と、
前記構造化文書格納手段に格納された構造化文書に含まれる各要素毎に、当該要素に対して適用された前記検索式処理手段によって抽出された検索条件の履歴を取得する検索履歴取得手段と、
索引を付与すべき、構造化文書に含まれる各要素毎に、前記検索履歴取得手段によって取得された、当該要素に対して適用された検索条件の履歴において最も多い検索種別に基づいて索引種別を決定する索引種別決定手段と、
前記索引種別決定手段によって前記各要素毎に決定された索引種別に基づいて、当該要素に対応する当該決定された索引種別の索引を構築して前記索引格納手段に格納する索引構築手段と
を具備することを特徴とする構造化文書管理システム。
In a structured document management system that builds an index of a structured document and stores it in the index storage means in order to speed up retrieval of the structured document stored in the structured document storage means,
A search expression processing means for analyzing a search expression given from the outside, extracting a search condition, and acquiring a set of search result candidates that match the search condition;
Search history acquisition means for acquiring, for each element included in the structured document stored in the structured document storage means, a history of search conditions extracted by the search expression processing means applied to the element; ,
For each element included in the structured document to be indexed, the index type is determined based on the most frequently used search type in the history of search conditions applied to the element acquired by the search history acquisition unit. Index type determining means for determining;
An index construction unit configured to construct an index of the determined index type corresponding to the element based on the index type determined for each element by the index type determination unit and store the index in the index storage unit. A structured document management system characterized by:
構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納する構造化文書管理システムにおいて、
索引を付与すべき、構造化文書に含まれる各要素毎に、当該要素の名前に基づいて索引種別を決定する索引種別決定手段と、
前記索引種別決定手段によって前記各要素毎に決定された索引種別に基づいて、当該要素に対応する当該決定された索引種別の索引を構築して前記索引格納手段に格納する索引構築手段と
を具備することを特徴とする構造化文書管理システム。
In a structured document management system that builds an index of a structured document and stores it in the index storage means in order to speed up retrieval of the structured document stored in the structured document storage means,
For each element included in the structured document to be indexed, index type determining means for determining an index type based on the name of the element;
An index construction unit configured to construct an index of the determined index type corresponding to the element based on the index type determined for each element by the index type determination unit and store the index in the index storage unit. A structured document management system characterized by:
外部から与えられる検索式を解析して検索条件を抽出し、その検索条件に合致する検索結果の候補の集合を取得する検索式処理手段を更に具備し、
前記索引種別決定手段は、索引を付与すべき、構造化文書に含まれる各要素毎に、当該要素の名前から推定される種別の検索条件であって、前記検索式処理手段によって抽出されて当該要素に対して適用される可能性の最も高い種別の検索条件に基づいて前記索引種別を決定する
ことを特徴とする請求項2記載の構造化文書管理システム。
It further comprises search expression processing means for analyzing a search expression given from outside, extracting a search condition, and acquiring a set of search result candidates that match the search condition,
The index type determination unit is a search condition of a type estimated from the name of the element for each element included in the structured document to be indexed, and is extracted by the search formula processing unit and The structured document management system according to claim 2, wherein the index type is determined based on a search condition of a type most likely to be applied to an element.
構造化文書に含まれる各要素の名前毎に、当該名前に対応付けて、当該名前から推定される種別の検索条件であって、前記検索式処理手段によって抽出されて当該名前の要素に対して適用される可能性の最も高い種別の検索条件に応じた索引種別の情報を格納した索引種別格納手段を更に具備し、
前記索引種別決定手段は、索引を付与すべき、構造化文書に含まれる各要素毎に、当該要素の名前をキーにして前記索引種別格納手段を参照することで、当該要素の名前に対応付けられている索引種別を、当該要素の値に適用する索引種別として決定する
ことを特徴とする請求項2または3のいずれか1項に記載の構造化文書管理システム。
For each element name included in the structured document, a search condition of a type estimated from the name in association with the name, which is extracted by the search expression processing means and applied to the element of the name It further comprises index type storage means for storing information of the index type corresponding to the search condition of the type most likely to be applied,
The index type determination means associates each element included in the structured document to which an index should be assigned with the name of the element by referring to the index type storage means using the name of the element as a key. The structured document management system according to any one of claims 2 and 3, wherein the index type being determined is determined as an index type to be applied to the value of the element.
構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納する構造化文書管理システムにおいて、
外部から与えられる検索式を解析して検索条件を抽出し、その検索条件に合致する検索結果の候補の集合を取得する検索式処理手段と、
前記構造化文書格納手段に格納される構造化文書の、当該構造化文書に含まれる要素の値のデータ型を含む構造を指定するためのスキーマ指定手段と、
索引を付与すべき、構造化文書に含まれる各要素のうち、前記スキーマ指定手段によって指定されている要素について、当該スキーマ指定手段によって指定されているデータ型に基づいて索引種別を決定する索引種別決定手段と、
前記索引種別決定手段によって前記各要素毎に決定された索引種別に基づいて、当該要素に対応する当該決定された索引種別の索引を構築して前記索引格納手段に格納する索引構築手段と
を具備することを特徴とする構造化文書管理システム。
In a structured document management system that builds an index of a structured document and stores it in the index storage means in order to speed up retrieval of the structured document stored in the structured document storage means,
A search expression processing means for analyzing a search expression given from the outside, extracting a search condition, and acquiring a set of search result candidates that match the search condition;
Schema designating means for designating a structure of the structured document stored in the structured document storage means, including a data type of an element value included in the structured document;
Among the elements included in the structured document to be indexed, the index type for determining the index type based on the data type specified by the schema specifying unit for the element specified by the schema specifying unit A determination means;
An index construction unit configured to construct an index of the determined index type corresponding to the element based on the index type determined for each element by the index type determination unit and store the index in the index storage unit. A structured document management system characterized by:
構造化文書格納手段に格納された構造化文書の検索を高速化するために、構造化文書の索引を構築して索引格納手段に格納する構造化文書管理システムにおいて、
索引を付与すべき、構造化文書に含まれる各要素毎に、Nグラム索引及び形態素解析による単語索引を含む複数の索引種別から、当該要素に基づいて索引種別を決定する索引種別決定手段と、
前記索引種別決定手段によって前記索引種別として前記単語索引が決定された場合、当該単語索引を構築するために対応する要素の値を形態素解析し、その解析結果に複数通りの解釈を持つ表記が含まれる場合、単語索引に代えて、Nグラム索引を構築して前記索引格納手段に格納する索引構築手段と
を具備することを特徴とする構造化文書管理システム。
In a structured document management system that builds an index of a structured document and stores it in the index storage means in order to speed up retrieval of the structured document stored in the structured document storage means,
Index type determination means for determining an index type based on the element from a plurality of index types including an N-gram index and a word index by morphological analysis for each element included in the structured document to be indexed;
When the word index is determined as the index type by the index type determining means, a morphological analysis is performed on the value of the corresponding element to construct the word index, and the analysis result includes a notation having multiple interpretations A structured document management system comprising: an index construction unit that constructs an N-gram index and stores it in the index storage unit instead of the word index.
前記索引構築手段は、前記索引種別決定手段によって前記索引種別として前記単語索引が決定された場合、当該単語索引を構築するために対応する要素の値を形態素解析し、その解析結果に、意味は同じであるが表記が異なる単語が含まれている場合、いずれかの表記に統一して単語索引を構築することを特徴とする請求項6記載の構造化文書管理システム。   When the word index is determined as the index type by the index type determination unit, the index construction unit performs morphological analysis on the value of the corresponding element in order to construct the word index, and the analysis result has the meaning 7. The structured document management system according to claim 6, wherein when a word that is the same but has a different notation is included, the word index is constructed by unifying any notation.
JP2007272912A 2007-10-19 2007-10-19 Structured document management system and program Expired - Fee Related JP4160627B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007272912A JP4160627B2 (en) 2007-10-19 2007-10-19 Structured document management system and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007272912A JP4160627B2 (en) 2007-10-19 2007-10-19 Structured document management system and program

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2004289382A Division JP4091586B2 (en) 2004-09-30 2004-09-30 Structured document management system, index construction method and program

Related Child Applications (3)

Application Number Title Priority Date Filing Date
JP2008137294A Division JP4237813B2 (en) 2008-05-26 2008-05-26 Structured document management system
JP2008137292A Division JP4304226B2 (en) 2008-05-26 2008-05-26 Structured document management system, structured document management method and program
JP2008137293A Division JP2008198236A (en) 2008-05-26 2008-05-26 Structured document management system

Publications (2)

Publication Number Publication Date
JP2008077673A true JP2008077673A (en) 2008-04-03
JP4160627B2 JP4160627B2 (en) 2008-10-01

Family

ID=39349591

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007272912A Expired - Fee Related JP4160627B2 (en) 2007-10-19 2007-10-19 Structured document management system and program

Country Status (1)

Country Link
JP (1) JP4160627B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011197809A (en) * 2010-03-17 2011-10-06 Fujitsu Ltd Search apparatus, search method and search program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011197809A (en) * 2010-03-17 2011-10-06 Fujitsu Ltd Search apparatus, search method and search program

Also Published As

Publication number Publication date
JP4160627B2 (en) 2008-10-01

Similar Documents

Publication Publication Date Title
US11853334B2 (en) Systems and methods for generating and using aggregated search indices and non-aggregated value storage
JP5492187B2 (en) Search result ranking using edit distance and document information
US8301437B2 (en) Tokenization platform
US20100094835A1 (en) Automatic query concepts identification and drifting for web search
JP4237813B2 (en) Structured document management system
US8229970B2 (en) Efficient storage and retrieval of posting lists
US20120124060A1 (en) Method and system of identifying adjacency data, method and system of generating a dataset for mapping adjacency data, and an adjacency data set
US8001138B2 (en) Word relationship driven search
US20110252313A1 (en) Document information selection method and computer program product
JP2008083769A (en) Document search apparatus and method
JP4091586B2 (en) Structured document management system, index construction method and program
JP4439496B2 (en) Search processing apparatus and program
JP4160627B2 (en) Structured document management system and program
JP4304226B2 (en) Structured document management system, structured document management method and program
JP2007133682A (en) Full text retrieval system and full text retrieval method therefor
JP2008026964A (en) Retrieval processor and program
JP2008198236A (en) Structured document management system
JP5906810B2 (en) Full-text search device, program and recording medium
JP4206266B2 (en) Full-text search device, processing method, processing program, and recording medium
JP4550876B2 (en) Structured document retrieval system and program
JP4521413B2 (en) Database management system and program
JP2005063366A (en) Information management apparatus and information management method
JPH09212523A (en) Entire sentence retrieval method
JP2013125429A (en) Analysis object determination device
JP5145202B2 (en) Document search apparatus and document search program

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080325

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080526

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20080715

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080717

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110725

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120725

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130725

Year of fee payment: 5

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees