JP3363501B2 - Text search device - Google Patents

Text search device

Info

Publication number
JP3363501B2
JP3363501B2 JP00620993A JP620993A JP3363501B2 JP 3363501 B2 JP3363501 B2 JP 3363501B2 JP 00620993 A JP00620993 A JP 00620993A JP 620993 A JP620993 A JP 620993A JP 3363501 B2 JP3363501 B2 JP 3363501B2
Authority
JP
Japan
Prior art keywords
text
keywords
unit
extracted
keyword
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.)
Expired - Fee Related
Application number
JP00620993A
Other languages
Japanese (ja)
Other versions
JPH06215035A (en
Inventor
佳代 中村
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.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric Co Ltd
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 Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP00620993A priority Critical patent/JP3363501B2/en
Publication of JPH06215035A publication Critical patent/JPH06215035A/en
Application granted granted Critical
Publication of JP3363501B2 publication Critical patent/JP3363501B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Machine Translation (AREA)

Description

【発明の詳細な説明】 【0001】 【産業上の利用分野】本発明は、テキスト(ここでテキ
ストとは、1つの文章、或るいは関連した複数文章によ
り構成された文書のことを言う。)の検索に際し、入力
する質問文のキーワードを抽出し、そのキーワードを含
むテキストを検索し、出力するテキスト検索装置に関す
るものである。 【0002】 【従来の技術】近年、コンピュータ技術の進歩や、文書
記憶装置の容量の増加により、多量のデータや文章を備
えるデータベースが普及しており、そのデータベースを
扱う機会も多く発生している。 【0003】これらのデータベースには、あらかじめハ
ードディスクなどの記憶装置に多量のデータが蓄積され
ており、そのデータに対して、キーワードを基にして検
索することが一般的である。 【0004】このようなテキスト検索装置におけるキー
ワードを基にした検索としては、例えば、特開平2−2
458号公報に開示されるように、与えられたテキスト
の形態素解析を行って、キーワードを抽出し、抽出され
たキーワードを基にして、記憶装置に格納されたテキス
トの検索を行い、キーワードが一致するテキストを出力
する方法が用いられている。 【0005】従来のテキスト検索装置を用いた検索方法
の一例を図5及び図6に基づいて説明する。 【0006】図5は、従来のテキスト検索装置の概略構
成図を示すものである。 【0007】同図において、1はキーワードを含む質問
文が入力される質問入力部、2は質問入力部1において
入力された質問文に対して形態素解析を施し、キーワー
ドの抽出を行うキーワード抽出部、3はキーワード抽出
部2において抽出されたキーワードを蓄えるキーワード
メモリ、4は検索対象となるテキストが既に蓄えられて
いる文書メモリ、5はキ−ワ−ドメモリ3に蓄えられて
いるキーワードを基にして、文書メモリ4から関連があ
るテキストを抽出するテキスト抽出部、6はテキスト抽
出部5で抽出されたテキストの出力を行う出力部、7は
テキスト検索装置全体の制御を司る制御部である。 【0008】図6は、図5に示した従来のテキスト検索
装置における出力部6からの検索結果であり、その出力
内容を示している。 【0009】以下に、図5に示すテキスト検索装置の動
作について、一例として、質問文”土星のリングについ
て知りたい。”が入力された場合を説明する。 【0010】まず、質問入力部1に”土星のリングにつ
いて知りたい。”という質問文が入力されると、キーワ
ード抽出部2は、キーワードを抽出するために、形態素
解析を行う。質問入力部1に入力された質問文は”土星
/の/リング/について/知り/たい/。”(ここで/
は形態素解析による区切りを表す。)のように形態素に
分解される。ここでは、キーワードとして名詞を用いる
こととしているので、”土星”及び”リング”が名詞と
して抽出される。従って、キーワード抽出部2におい
て、”土星”及び”リング”がキーワードとして抽出さ
れ、キーワードメモリ3に蓄えられる。この質問文にお
ける検索要求の内容は”土星のリング”に関することで
あり、キーワードである”土星”と”リング”が係受け
の関係になっているものが最も要求されるテキストであ
る。 【0011】キーワードメモリ3にキーワードが蓄積さ
れると、テキスト抽出部5は、文書メモリ4に蓄えられ
ているテキストから、キーワードを含むテキストを順次
抽出していく。 【0012】表1は文書メモリ4に格納されている様々
なテキストの一部を示したものである。 【0013】 【表1】【0014】テキスト抽出部5は、文書メモリ4の内容
から順次テキストの検索を行う。以下にその手順を示
す。 【0015】テキスト抽出部5は、文書メモリ4のテキ
ストからキーワード”土星”が含まれるか否かの判定を
全てのテキストについて行う。まず、”土星に関して言
えば、その中のリングは土星の象徴と言える。”(以
下、テキスト1という。)というテキストが抽出され
る。検索を続けていくと、”土星のリングは、太陽系の
中で最も美しいものの一つだ。”(以下、テキスト3と
いう。)というテキストが検索される。さらに検索を続
けていくと、”土星は、衛星に取り巻かれている。そし
てリングは、衛星からエネルギーを奪われている。”
(以下、テキスト4という。)というテキストが抽出さ
れる。さらに続けると、”土星においてリングはどのよ
うな働きをしているのだろうか?”(以下、テキスト6
という。)というテキストが抽出される。さらに、続け
ると”土星は太陽系の惑星の一つである。”(以下、テ
キスト7という。)というテキストが抽出される。 【0016】以上のように、テキスト1、テキスト3、
テキスト4、テキスト6、及びテキスト7が抽出され
る。テキスト2及びテキスト5については、キーワード
である”土星”が含まれていないため抽出されない。 【0017】続いて、テキスト抽出部5は、抽出された
テキスト1、テキスト3、テキスト4、テキスト6、及
びテキスト7について次のキーワード”リング”が含ま
れているか否かの判定を行う。テキスト1、テキスト
3、テキスト4、及びテキスト6には、キーワード”リ
ング”が含まれるが、テキスト7には、キーワード”リ
ング”が含まれない。このため、テキスト抽出部5から
は、テキスト1、テキスト3、テキスト4、及びテキス
ト6が抽出され、出力部6に伝えられ、図6に示すよう
に出力部6においてテキスト1、テキスト3、テキスト
4、及びテキスト6の順番に出力される。 【0018】このように、従来、キーワードによる検索
の結果、全種類のキーワードを含むテキストが、文書メ
モリ4に蓄えられている順番に出力部6から出力されて
いた。 【0019】 【発明が解決しようとする課題】上記のような構成で
は、キーワードを含むテキストを抽出することは可能で
あるが、文書メモリ4に蓄えられている順番に出力を行
っていくため、質問文の意図する検索要求の内容を的確
に表すテキストから出力されるとは限らなかった。 【0020】本発明は上記問題点に鑑みなされたもので
あり、抽出されたテキストの構文解析結果を基にして、
テキストの出力の順番に優先順位を与え、検索要求の内
容を的確に表すテキストから順番に出力するテキスト検
索装置を提供するものである。 【0021】 【課題を解決するための手段】上記問題点を解決するた
めに、本発明のテキスト検索装置は、複数のテキストが
格納されている文書メモリと、該文書メモリに格納され
ているテキストを抽出するのに要する質問文を入力する
質問入力部と、該質問入力部に入力された質問文から複
数種類のキーワードを抽出するキーワード抽出部と、該
キーワード抽出部で抽出されたキーワードを基にして、
上記文書メモリから上記キーワードを含んだテキストを
抽出するテキスト抽出部と、該テキスト抽出部から抽出
されたテキストを出力する出力部と、上記テキスト抽出
部で抽出されたテキストに対して、構文解析を施す構文
解析判定部と、を備え、該構文解析判定部は、上記キー
ワード抽出部で抽出されたキーワード間の距離による判
定を行い、該キーワード間の距離が短い順番に、上記出
力部から上記テキストを出力せしめる優先順位を決定す
るものである。 【0022】 【作用】本発明は、上述した構成により、質問文のキー
ワードを用いて、抽出されたテキストに対してキーワー
ド間の距離による判定を行い、該キーワード間の距離が
短い順番に抽出されたテキストに優先順位を与えること
により、検索要求を的確に表すテキストを自動的に優先
して出力するテキスト検索装置を提供することが可能で
ある。 【0023】 【実施例】以下に、本発明の一実施例であるテキスト検
索装置を図1乃至図4に基づいて説明し、従来と同一の
構成については同一番号を付し、その説明は省略する。 【0024】図1は、本発明のテキスト検索装置の概略
構成図、図2及び図3は、本発明の特徴である構文解析
判定部8の処理の流れを示すフローチャート、図4は、
本発明を実施した場合の出力結果である。 【0025】本発明が従来例と異なる点は、テキスト抽
出部5と出力部6の間に構文解析判定部8を設けたこと
であり、この構文解析判定部8は、質問入力部1に入力
された質問文及びテキスト抽出部5で抽出されたテキス
トについて構文解析を行うとともに、これらの構文解析
結果を基にして、テキスト抽出部5で抽出されたテキス
トの並び替えを行い、出力部6から出力するテキストの
優先順位を決定する機能を有する。この構文解析判定部
8における処理概要を図2及び図3に示すフローチャー
トを基にして説明する。 【0026】S1においては、質問入力部1に入力され
た質問文の構文解析を行い、キーワード抽出部2で抽出
されたキーワードの構文情報、即ちキーワードがどの
文、どの文節に含まれるか、或るいはキーワード間の係
受けの関係などを調べる。S2においては、テキスト抽
出部5で抽出されたテキストの1つを構文解析判定部8
に読み込ませる。S3においては、S2において読み込
まれたテキストから形態素解析を行い、キーワードを抽
出するとともに、読み込まれたテキストにおけるキーワ
ードの構文情報(キーワードがどの文、どの文節に含ま
れるか、或るいはキーワード間の係受けの関係など)を
調べる。 【0027】S4、S6、及びS8においては、S3で
抽出されたキーワードの構文情報を基にして出力部6に
おける優先順位を決定するものであり、まず、S4で
は、テキスト抽出部5で抽出されたテキストにおいて、
全種類のキーワードが1つの文中に存在するかどうかを
判定し、全種類のキーワードが1つの文中に存在する場
合には、S6の処理へ進み、全種類のキーワードが1つ
の文中に存在しない場合には、S5へ進む。S5におい
ては、全種類のキーワードが1つの文中に存在しない場
合の優先順位を決定し、全種類のキーワードが1つの文
中に存在しない場合、キーワード間の関係は、ほとんど
無いと判定し、優先順位(以下、IDという。)は4番
目(ID=4)と決定する(以下、ID=nと書くと、
優先順位はn番目であることを示す。)。 【0028】次に、S6においては、テキスト抽出部5
で抽出されたテキストにおいて、全種類のキーワードが
1つの文節中に存在するかどうかを判定し、全種類のキ
ーワードが1つの文節中に存在する場合は、S8へ進
み、全種類のキーワードが1つの文節中に存在しない場
合には、S7に進む。S7においては、全種類のキーワ
ードが1つの文節中に存在しない場合の優先順位を決定
し、全種類のキーワードが1つの文節中に存在しない場
合、キーワード間の関係は、あまり無いと判定し、ID
=3と決定する。 【0029】S8においては、テキスト抽出部5で抽出
されたテキストにおけるキーワード間の関係と、質問入
力部1に入力された質問文におけるキーワード間の関係
とが同じであるかどうかの判定を行い、同じ関係の場合
には、S10に進み、それらの関係が異なる場合には、
S9に進む。 【0030】S9においては、テキスト抽出部5で抽出
されたテキストにおけるキーワード間の関係と、質問入
力部1に入力された質問文におけるキーワード間の関係
とが異なる場合の優先順位を決定し、この場合は、検索
要求の内容に近いが、一致はしていないと判断し、ID
=2と決定する。 【0031】S10においては、テキスト抽出部5で抽
出されたテキストにおけるキーワード間の関係と、質問
入力部1に入力された質問文におけるキーワード間の関
係とが同じ場合の優先順位を決定し、この場合は、検索
要求の内容に一致していると判断し、ID=1と決定す
る。 【0032】S11においては、テキスト抽出部5で抽
出された全てのテキストについて、上記S2乃至S10
の処理が終了したかどうかを判定するものであり、抽出
された全てのテキストについて終了した場合には、S1
2へ進む。S12においては、S2乃至S10において
決定されたIDを基にして、優先順位の高い(IDが小
さい。)ものから順番に、テキストを並べ替えるもので
ある。 【0033】S13においては、並べ替えられたテキス
トに、同一優先順位のものがあるかどうかの判定を行
い、同一優先順位のものがある場合には、S14に進
み、同一優先順位のものがない場合には、S17へ進
む。 【0034】S14乃至S16では、同一優先順位のも
のがある場合に更に別な方法で、優先順位を決定する。
S14では、S3において抽出されたキーワードの中
で、上記S4乃至S10における優先順位の決定に用い
られなかったキーワードが存在するかどうかの判定を行
い、そのキーワードが存在する場合には、このキーワー
ドにより、S3で読み込まれたテキストに対してS4乃
至S10を再度行い、優先順位を決定する。 【0035】S15及びS16では、上記S2乃至S1
4の処理を経ても優先順位が同じ場合には、キーワード
間の距離(あるキーワードと他のキーワードの間に存在
する文字数など)により、 優先順位を決定する。 【0036】S17では、上記S2乃至S16の処理に
おいて決定された優先順位に基づいて、優先順位の高い
テキストから順番に、出力部6へ伝送する。 【0037】以下に、一例として”土星のリングについ
て知りたい。”という質問文に関する検索について、表
1、図2、及び図3を参照しながら、説明する。 【0038】質問入力部1に入力された質問文から、テ
キスト抽出部5のテキスト抽出までの流れは、従来例の
テキスト抽出の流れと同じであるので、ここでは説明は
省略し、以下では、テキスト抽出部5で抽出されたテキ
ストを、構文解析判定部8において優先順位を付ける方
法について図2及び図3を用いて説明する。 【0039】まず、図2のS1において、質問入力部1
から入力された”土星のリングについて知りたい。”と
いう質問文の形態素解析が行われ、”土星”、”リン
グ”がキーワードとして抽出され、さらに構文解析が行
われる。キーワードの”土星”、”リング”は同一文、
同一文節中であり、キーワードが係受けの関係であるこ
とが判定される。この結果が、入力された質問文の構文
解析結果として、構文解析判定部8に記憶される。 【0040】次に、S2においてテキスト抽出部5で抽
出されたテキストが、順番に構文解析判定部8に読み込
まれ、S3において形態素解析が施される。 【0041】S3においては、まず、テキスト1の形態
素解析を行い、”土星/に/関して/言え/ば/、/そ
の/中の/リング/は/土星/の/象徴/と/言える
/。”というように解析される。次に、この形態素解析
の結果を基にして、構文解析によりIDが決定される。
テキスト1についてキーワードである”土星”と”リン
グ”が同一文中にあるかどうかが判定される。テキスト
1は、同一文中にキーワードが存在するために、処理が
S6へ進められる。S6においては、同一文節中に、キ
ーワードが存在するかどうかの判定が施される。テキス
ト1のキーワードである”土星”と”リング”は同一文
節に存在しないので、処理がS7へ進められて、ID=
3と決定された後、S11へ進む。S11においては、
テキスト抽出部5において抽出された全てのテキストに
ついて、構文解析によりIDが決定されたかどうかが調
べられる。テキスト抽出部5において抽出された全ての
テキストについて終了した場合には、S12へ進み、終
了していない場合には、S2に戻って繰り返される。 【0042】以下に、テキスト3、テキスト4、及びテ
キスト6の構文解析の例について説明する。 【0043】続いて、S3においてテキスト3の形態素
解析を行う。テキスト3は”土星/の/リング/は/、
/太陽系/の中で/最も/美しい/もの/の/一つ/だ
/。”と解析される。この解析されたテキスト3もテキ
スト1と同様にS4、S6、S8及びS10が施され
る。テキスト3の構文解析結果と、質問文の構文解析結
果とは同じであるので、ID=1と決定される。 【0044】さらに続いて、テキスト抽出部5で抽出さ
れた3番目のテキストについて同様に繰り返す。テキス
ト4は”土星/は/、/衛星/に/取り巻か/れ/てい
る/。/そして/リング/は/、/衛星/から/エネル
ギー/を/奪わ/れ/ている/。”というように形態素
解析され、S4及びS5の処理を経て、IDが決定さ
れ、テキスト4は、ID=4となる。さらに、テキスト
6についても、”土星/において/リング/は/どのよ
うな/働き/を/し/ている/の/だろうか/?”とい
うように形態素解析され、S4、S6、S8及びS9の
処理を経て、ID=2と決定される。以上により、テキ
スト抽出部5で抽出されたテキスト全てについて構文解
析によりIDが決定される。 【0045】最終的に構文解析によりIDが決定される
と、図3のS12において、構文解析による優先順位の
高いものから出力の順番が決定される。S12におい
て、同一優先順位のものが存在する場合には、S13に
進み、存在しない場合には、S17により、出力部6に
対して、出力する順番を指定する。本実施例において
は、テキスト1はID=3、テキスト3はID=1、テ
キスト4はID=4、テキスト6はID=2であるの
で、S17においては、テキスト3、テキスト6、テキ
スト1、テキスト4の順番で出力部6から出力される。
その結果を図4に示す。 【0046】本実施例においては、同一優先順位のもの
がない場合について説明したが、同一優先順位のものが
複数ある場合には、図3のS14に示すように、優先順
位決定の対象となったキーワード以外に存在するキーワ
ードにより、判定を行うことも可能である。また、S1
4を行っても全く同一の場合には、S15、S16に示
すように、抽出されたテキストにおけるキーワード間の
距離(キーワード間の文字数など)より優先順位を決定
することも可能である。 【0047】尚、本実施例においては、キーワード抽出
部2で抽出されたキーワードが2つの場合を例に説明し
たが、キーワードが3つ以上ある場合も基本的には同じ
であり、例えば、キーワードが3つの場合には、3つの
キーワードによる構文解析結果を用いたり、或るいは質
問文において出現頻度の多いキーワードに関する構文解
析結果を用いることも可能である。 【0048】 【発明の効果】本発明は、以上の説明から明らかなよう
に、キーワードにより抽出されたテキストを出力部から
出力する順番の優先順位を決定することができるため、
検索要求を的確に表すテキストから順次出力することが
可能となる。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a text (here, a text refers to a document composed of one sentence or a plurality of related sentences). The present invention relates to a text search device that extracts a keyword of a question sentence to be input, searches for a text including the keyword, and outputs the extracted text. 2. Description of the Related Art In recent years, with the progress of computer technology and the increase in the capacity of document storage devices, databases having a large amount of data and text have become widespread, and there have been many opportunities to handle the databases. . In these databases, a large amount of data is stored in a storage device such as a hard disk in advance, and it is general to search the data based on a keyword. As a search based on a keyword in such a text search device, for example, Japanese Patent Laid-Open No. 2-2
As disclosed in Japanese Patent No. 458, a morphological analysis of a given text is performed to extract a keyword, a search of a text stored in a storage device is performed based on the extracted keyword, and the keyword matches. A method of outputting text to be used is used. An example of a search method using a conventional text search device will be described with reference to FIGS. FIG. 5 is a schematic block diagram of a conventional text search apparatus. In FIG. 1, reference numeral 1 denotes a question input unit into which a question sentence including a keyword is input; Reference numeral 3 denotes a keyword memory for storing the keywords extracted by the keyword extracting unit 2, reference numeral 4 denotes a document memory in which a text to be searched has already been stored, and reference numeral 5 denotes a keyword memory based on the keywords stored in the keyword memory 3. A text extraction unit for extracting a relevant text from the document memory 4, an output unit 6 for outputting the text extracted by the text extraction unit 5, and a control unit 7 for controlling the entire text search device. FIG. 6 shows a search result from the output unit 6 in the conventional text search apparatus shown in FIG. 5, and shows the output contents. Hereinafter, as an example of the operation of the text search apparatus shown in FIG. 5, a case will be described in which the question sentence "I want to know about Saturn's ring" is input. First, when a question sentence "I want to know about Saturn's ring" is input to the question input unit 1, the keyword extraction unit 2 performs a morphological analysis to extract a keyword. The question sentence input to the question input section 1 is "Saturn / no / ring / about / know / want /."
Represents a break by morphological analysis. Decomposed into morphemes as in ()). Here, since nouns are used as keywords, “Saturn” and “ring” are extracted as nouns. Therefore, the keyword extraction unit 2 extracts “Saturn” and “ring” as keywords and stores them in the keyword memory 3. The content of the search request in this question text is related to “Ring of Saturn”, and the text that is most requested is one in which the keywords “Saturn” and “ring” are related. When keywords are stored in the keyword memory 3, the text extracting unit 5 sequentially extracts texts including the keywords from the texts stored in the document memory 4. Table 1 shows a part of various texts stored in the document memory 4. [Table 1] The text extracting unit 5 sequentially searches for text from the contents of the document memory 4. The procedure is described below. The text extracting unit 5 determines whether or not the keyword "Saturn" is included in the text in the document memory 4 for all texts. First, the text "Saturn is said to be a symbol of Saturn" (hereinafter referred to as text 1) is extracted. As you continue your search, you will find the text "The Saturn's ring is one of the most beautiful in the solar system." The search continued, "Saturn is surrounded by satellites, and the ring is being deprived of energy from the satellites."
(Hereinafter referred to as text 4) is extracted. To continue, "How does the ring work on Saturn?"
That. ) Is extracted. Further, the text “Saturn is one of the planets of the solar system” (hereinafter referred to as text 7) is extracted. As described above, text 1, text 3,
Text 4, text 6, and text 7 are extracted. The text 2 and the text 5 are not extracted because the keyword “Saturn” is not included. Subsequently, the text extraction unit 5 determines whether or not the extracted keyword 1, text 3, text 4, text 6, and text 7 include the next keyword "ring". Text 1, text 3, text 4, and text 6 include the keyword “ring”, but text 7 does not include the keyword “ring”. For this reason, text 1, text 3, text 4, and text 6 are extracted from the text extraction unit 5 and transmitted to the output unit 6, and as shown in FIG. 4 and text 6 in this order. As described above, conventionally, as a result of a search using a keyword, texts including all types of keywords have been output from the output unit 6 in the order stored in the document memory 4. With the above configuration, it is possible to extract a text including a keyword, but since the text is output in the order stored in the document memory 4, It was not always output from a text that accurately represented the content of the search request intended by the question sentence. The present invention has been made in view of the above problems, and based on a result of parsing an extracted text,
It is an object of the present invention to provide a text search apparatus that gives priority to the order of outputting texts and outputs the texts in order from the text that accurately represents the content of the search request. In order to solve the above problems, a text search apparatus according to the present invention comprises a document memory storing a plurality of texts, and a text memory stored in the document memory. A question input unit for inputting a question sentence required for extracting a keyword, a keyword extraction unit for extracting a plurality of types of keywords from the question sentence input to the question input unit, and a keyword And then
A text extraction unit for extracting the text including the keyword from the document memory, an output unit for outputting the text extracted from the text extraction unit, and a syntax analysis for the text extracted by the text extraction unit. And a syntactic analysis judging unit for applying the key.
Judgment based on the distance between keywords extracted by the word extraction unit
The keywords in the order in which the distance between the keywords is short.
Determine the priority order for the above section to output the above text
Things. [0022] DETAILED DESCRIPTION OF THE INVENTION The present invention, keywords with the configuration described above, by using the keywords of the question sentence, the extracted text
Is determined based on the distance between the keywords, and the distance between the keywords is
By giving priorities to texts extracted in short order, it is possible to provide a text search device that automatically prioritizes and outputs texts that accurately represent search requests. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS A description will now be given, with reference to FIGS. 1 to 4, of a text search apparatus according to one embodiment of the present invention. I do. FIG. 1 is a schematic configuration diagram of a text search apparatus according to the present invention, FIGS. 2 and 3 are flowcharts showing a processing flow of a parsing determination unit 8 which is a feature of the present invention, and FIG.
It is an output result at the time of implementing the present invention. The present invention is different from the conventional example in that a syntax analysis judging unit 8 is provided between the text extracting unit 5 and the output unit 6. The parsing is performed on the extracted question text and the text extracted by the text extracting unit 5, and the text extracted by the text extracting unit 5 is rearranged based on the parsing result. It has a function to determine the priority of the text to be output. An outline of the processing in the syntax analysis determination unit 8 will be described with reference to the flowcharts shown in FIGS. At S1, the syntax of the question sentence input to the question input unit 1 is analyzed, and the syntax information of the keyword extracted by the keyword extraction unit 2, that is, which sentence and which phrase contains the keyword, Or, check the dependency relationship between keywords. In S2, one of the texts extracted by the text extraction unit 5 is sent to the syntax analysis determination unit 8
To read. In S3, morphological analysis is performed from the text read in S2 to extract keywords, and syntax information of the keywords in the read text (in which sentence or in which phrase the keywords are included, or between keywords). (Such as dependency relationships). In S4, S6, and S8, the priorities in the output unit 6 are determined based on the syntax information of the keywords extracted in S3. In the text
It is determined whether all types of keywords exist in one sentence. If all types of keywords exist in one sentence, the process proceeds to S6, and if all types of keywords do not exist in one sentence. To S5. In S5, the priority order when all types of keywords do not exist in one sentence is determined. When all types of keywords do not exist in one sentence, it is determined that there is almost no relationship between the keywords. (Hereinafter referred to as ID) is determined to be the fourth (ID = 4) (hereinafter, writing ID = n,
The priority indicates the n-th priority. ). Next, in S6, the text extraction unit 5
It is determined whether or not all types of keywords are present in one phrase in the text extracted in step. If all types of keywords are present in one phrase, the process proceeds to S8, where all types of keywords are 1 If it does not exist in one phrase, the process proceeds to S7. In S7, a priority is determined when all types of keywords do not exist in one phrase, and when all types of keywords do not exist in one phrase, it is determined that there is not much relationship between the keywords, ID
= 3. In S8, it is determined whether or not the relationship between the keywords in the text extracted by the text extraction unit 5 and the relationship between the keywords in the question sentence input to the question input unit 1 are the same. If the relationships are the same, the process proceeds to S10. If the relationships are different,
Proceed to S9. In S9, the priority order is determined when the relationship between the keywords in the text extracted by the text extraction unit 5 and the relationship between the keywords in the question sentence input to the question input unit 1 are different. In this case, it is determined that the content is close to the content of the search request but does not match,
= 2 is determined. In S10, the priority order is determined when the relationship between the keywords in the text extracted by the text extraction unit 5 and the relationship between the keywords in the question sentence input to the question input unit 1 are the same. In this case, it is determined that the content matches the content of the search request, and ID = 1 is determined. In S11, the above-mentioned S2 to S10 are executed for all the texts extracted by the text extraction unit 5.
It is determined whether or not the processing has been completed. If the processing has been completed for all the extracted texts, S1
Proceed to 2. In S12, based on the IDs determined in S2 to S10, the texts are rearranged in descending order of priority (lower IDs). In S13, it is determined whether or not the rearranged texts have the same priority. If there is one having the same priority, the process proceeds to S14, and there is no text having the same priority. In this case, the process proceeds to S17. In steps S14 to S16, if there is the same priority, the priority is determined by another method.
In S14, it is determined whether or not any of the keywords extracted in S3 has not been used in the determination of the priority in S4 to S10. , S3 are performed again on the text read in S3, and the priorities are determined. In S15 and S16, the above S2 to S1
If the priority is the same even after the processing of step 4, the priority is determined based on the distance between the keywords (the number of characters existing between a certain keyword and another keyword). In S17, based on the priorities determined in the processing of S2 to S16, the texts with the highest priority are transmitted to the output unit 6 in order. Hereinafter, as an example, a search related to the question sentence "I want to know about Saturn's ring" will be described with reference to Table 1, FIG. 2 and FIG. The flow from the question sentence input to the question input unit 1 to the text extraction by the text extraction unit 5 is the same as the flow of the text extraction of the conventional example, and the description is omitted here. A method of assigning priorities to the text extracted by the text extraction unit 5 in the syntax analysis determination unit 8 will be described with reference to FIGS. First, in S1 of FIG. 2, the question input unit 1
A morphological analysis of the question sentence "I want to know about Saturn's ring." Is performed, and "Saturn" and "ring" are extracted as keywords, and further syntax analysis is performed. The keywords "Saturn" and "Ring" are the same sentence,
It is determined that the keywords are in the same phrase and that the keywords are related. This result is stored in the syntax analysis determination unit 8 as a result of the syntax analysis of the input question sentence. Next, the text extracted by the text extraction unit 5 in S2 is sequentially read by the syntax analysis determination unit 8, and morphological analysis is performed in S3. In S3, first, a morphological analysis of the text 1 is performed, and "Saturn / about / say / ba /, / the / middle / ring / was / saturn / of / symbol / say / . ". Next, an ID is determined by syntax analysis based on the result of the morphological analysis.
It is determined whether the keywords “Saturn” and “ring” are in the same sentence for text 1. Since the keyword of the text 1 exists in the same sentence, the process proceeds to S6. In S6, it is determined whether a keyword exists in the same phrase. Since the keywords "Saturn" and "Ring" of text 1 do not exist in the same phrase, the process proceeds to S7, where ID =
After the determination is 3, the process proceeds to S11. In S11,
For all the texts extracted by the text extraction unit 5, it is checked whether or not the IDs have been determined by the syntax analysis. If the processing has been completed for all the texts extracted by the text extraction unit 5, the process proceeds to S12, and if not completed, the process returns to S2 and repeats. An example of parsing text 3, text 4, and text 6 will be described below. Subsequently, the morphological analysis of the text 3 is performed in S3. Text 3 is "Saturn / no / ring / wa /,
/ In the solar system / in / most / beautiful / things / one / one /. The analyzed text 3 is also subjected to S4, S6, S8, and S10 in the same manner as the text 1. Since the syntax analysis result of the text 3 is the same as the syntax analysis result of the question sentence, , ID = 1 is repeated, and the same is repeated for the third text extracted by the text extraction unit 5. Text 4 is described as "Saturn / ha /, / satellite // surrounding / surrounding. /ing/. / And / ring / has /, / satellite / from / energy / deprived / deprived /. The morphological analysis is performed as described above, and the ID is determined through the processing of S4 and S5, and the text 4 has ID = 4. / Work / does / does / no / maybe /? And the morphological analysis is performed as described above, and ID = 2 is determined through the processing of S4, S6, S8, and S9. As described above, the IDs are determined by parsing all the texts extracted by the text extracting unit 5. When the ID is finally determined by the syntax analysis, the output order is determined from those having the highest priority by the syntax analysis in S12 of Fig. 3. In S12, those having the same priority exist. If so, the process proceeds to S13, and if not, in S17, the output order is specified to the output unit 6. In the present embodiment, text 1 has ID = 3 and text 3 has ID = 3. 1, text 4 has ID = 4, and text 6 has ID = 2. Therefore, in step S17, the output unit 6 outputs text 3, text 6, text 1, and text 4 in this order. Is forced.
FIG. 4 shows the results. In this embodiment, the case where there is no one having the same priority is described. However, when there are a plurality of ones having the same priority, as shown in S14 of FIG. It is also possible to make a determination based on keywords that exist other than the keywords that have been used. Also, S1
If the same is obtained even after performing step 4, it is possible to determine the priority order based on the distance between keywords (such as the number of characters between keywords) in the extracted text, as shown in S15 and S16. In this embodiment, the case where the keyword extracted by the keyword extraction unit 2 is two has been described as an example. However, the case where there are three or more keywords is basically the same. In the case where there are three, it is also possible to use the result of parsing with three keywords, or the result of parsing for a keyword with a high frequency of appearance in a question sentence. According to the present invention, as is apparent from the above description, the text extracted by the keyword is output from the output unit.
Since the priority of the output order can be determined,
It is possible to sequentially output a search request from a text that accurately represents the search request.

【図面の簡単な説明】 【図1】本発明の構文解析判定部を備えたテキスト検索
装置の概略構成図 【図2】本発明に係る構文解析判定部の処理の流れを示
すフローチャート 【図3】本発明に係る構文解析判定部の処理の流れを示
すフローチャート 【図4】本発明を実施した場合の出力結果を示す図 【図5】従来例のテキスト検索装置の概略構成図 【図6】従来例による出力結果を示す図 【符号の説明】 1 質問入力部 2 キーワード抽出部 3 キーワードメモリ 4 文書メモリ 5 テキスト抽出部 6 出力部 7 制御部 8 構文解析判定部
BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a schematic configuration diagram of a text search device including a syntax analysis determination unit according to the present invention. FIG. 2 is a flowchart illustrating a processing flow of the syntax analysis determination unit according to the present invention. FIG. 4 is a flowchart showing a flow of processing of a parsing determination unit according to the present invention. FIG. 4 is a diagram showing an output result when the present invention is implemented. FIG. 5 is a schematic configuration diagram of a conventional text search device. Diagram showing output result according to conventional example [Description of reference numerals] 1 Question input unit 2 Keyword extraction unit 3 Keyword memory 4 Document memory 5 Text extraction unit 6 Output unit 7 Control unit 8 Syntax analysis determination unit

フロントページの続き (58)調査した分野(Int.Cl.7,DB名) G06F 17/30 350 G06F 17/30 170 G06F 17/30 330 G06F 17/27 JICSTファイル(JOIS)Continuation of the front page (58) Field surveyed (Int.Cl. 7 , DB name) G06F 17/30 350 G06F 17/30 170 G06F 17/30 330 G06F 17/27 JICST file (JOIS)

Claims (1)

(57)【特許請求の範囲】 【請求項1】 複数のテキストが格納されている文書メ
モリと、該文書メモリに格納されているテキストを抽出
するのに要する質問文を入力する質問入力部と、該質問
入力部に入力された質問文から複数種類のキーワードを
抽出するキーワード抽出部と、該キーワード抽出部で抽
出されたキーワードを基にして、上記文書メモリから上
記キーワードを含んだテキストを抽出するテキスト抽出
部と、該テキスト抽出部から抽出されたテキストを出力
する出力部と、上記テキスト抽出部で抽出されたテキス
トに対して、構文解析を施す構文解析判定部と、を備
え、該構文解析判定部は、上記キーワード抽出部で抽出され
たキーワード間の距離による判定を行い、該キーワード
間の距離が短い順番に、上記出力部から上記テキストを
出力せしめる優先順位を決定することを特徴とするテキ
スト検索装置。
(57) [Claims] (1) A document memory storing a plurality of texts, and a question input unit for inputting a question sentence required for extracting the text stored in the document memory. A keyword extracting unit for extracting a plurality of types of keywords from the question sentence input to the question input unit, and extracting a text including the keywords from the document memory based on the keywords extracted by the keyword extracting unit. text extraction unit that includes an output unit for outputting the text extracted from the text extracting unit, on the extracted text in the text extraction unit, a syntactic analysis unit for performing parsing, the, above constituting sentence The analysis determination unit is extracted by the keyword extraction unit.
The keyword is determined based on the distance between the keywords.
The text is output from the output unit in the order of the shortest distance.
A text characterized by determining the priority order to be output
Strike search device.
JP00620993A 1993-01-18 1993-01-18 Text search device Expired - Fee Related JP3363501B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP00620993A JP3363501B2 (en) 1993-01-18 1993-01-18 Text search device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP00620993A JP3363501B2 (en) 1993-01-18 1993-01-18 Text search device

Publications (2)

Publication Number Publication Date
JPH06215035A JPH06215035A (en) 1994-08-05
JP3363501B2 true JP3363501B2 (en) 2003-01-08

Family

ID=11632145

Family Applications (1)

Application Number Title Priority Date Filing Date
JP00620993A Expired - Fee Related JP3363501B2 (en) 1993-01-18 1993-01-18 Text search device

Country Status (1)

Country Link
JP (1) JP3363501B2 (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3612769B2 (en) * 1994-05-25 2005-01-19 富士ゼロックス株式会社 Information search apparatus and information search method
JPH08272782A (en) * 1995-03-29 1996-10-18 Fuji Xerox Co Ltd Document retrieval device
US5933822A (en) * 1997-07-22 1999-08-03 Microsoft Corporation Apparatus and methods for an information retrieval system that employs natural language processing of search results to improve overall precision
JP2006163723A (en) * 2004-12-06 2006-06-22 Hitachi Software Eng Co Ltd Document search method
JP4435144B2 (en) * 2006-12-04 2010-03-17 株式会社東芝 Data search system and program
US8510272B2 (en) * 2007-04-20 2013-08-13 General Electric Company Decision support response systems and methods
JP5493779B2 (en) * 2009-11-30 2014-05-14 富士ゼロックス株式会社 Information search program and information search apparatus
JP5915274B2 (en) * 2012-03-09 2016-05-11 富士通株式会社 Information search method, program, and information search apparatus

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2885487B2 (en) * 1990-07-26 1999-04-26 日本電信電話株式会社 Document information retrieval device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
稲垣 他,係り受け関係を用いた類似文書検索システム,情報処理学会第39回全国大会講演論文集,日本,社団法人 情報処理学会,1989年10月16日,第1分冊 1G−5,pp.678−679.

Also Published As

Publication number Publication date
JPH06215035A (en) 1994-08-05

Similar Documents

Publication Publication Date Title
EP0953192B1 (en) Natural language parser with dictionary-based part-of-speech probabilities
JP3272288B2 (en) Machine translation device and machine translation method
US7630880B2 (en) Japanese virtual dictionary
JP3363501B2 (en) Text search device
JP4935243B2 (en) Search program, information search device, and information search method
JP5285491B2 (en) Information retrieval system, method and program, index creation system, method and program,
JP2008204133A (en) Answer search apparatus and computer program
KR100452024B1 (en) Searching engine and searching method
JPH07134720A (en) Method and device for presenting relative information in sentence preparing system
JP2001101184A (en) Method and device for generating structurized document and storage medium with structurized document generation program stored therein
JPH1145249A (en) Information retrieval device and computer-readable recording medium where program for making computer function as same device is recorded
JP2001034630A (en) System and method for document base retrieval
JP3358100B2 (en) Japanese question message analysis method and device
JPH07152778A (en) Document retrieval device
JPH0320866A (en) Text base retrieval system
JP3884001B2 (en) Language analysis system and method
JPH05233689A (en) Automatic document abstracting method
JP2005234688A (en) Method, program and apparatus for discriminating important language, document retrieval apparatus and key word extraction apparatus
JPH08153112A (en) Device and method for document preparation
JPH05225232A (en) Automatic text pre-editor
JPH0973454A (en) Device and method for document preparation
JPH08137883A (en) Dictionary device
JPH05307570A (en) Document management device
JPH1139347A (en) Text retrieval system, index generation device, text retrieval device and recording medium which computer can read
JPH09101951A (en) Document retrieving device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20071025

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20081025

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20081025

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20091025

Year of fee payment: 7

LAPS Cancellation because of no payment of annual fees