WO2010119720A1 - テキストデータ処理装置およびプログラム - Google Patents

テキストデータ処理装置およびプログラム Download PDF

Info

Publication number
WO2010119720A1
WO2010119720A1 PCT/JP2010/052358 JP2010052358W WO2010119720A1 WO 2010119720 A1 WO2010119720 A1 WO 2010119720A1 JP 2010052358 W JP2010052358 W JP 2010052358W WO 2010119720 A1 WO2010119720 A1 WO 2010119720A1
Authority
WO
WIPO (PCT)
Prior art keywords
category
character string
text data
record
text
Prior art date
Application number
PCT/JP2010/052358
Other languages
English (en)
French (fr)
Inventor
宏二 伊藤
考司 河原
Original Assignee
ディジタル・ワークス株式会社
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 ディジタル・ワークス株式会社 filed Critical ディジタル・ワークス株式会社
Priority to US13/263,977 priority Critical patent/US20120030204A1/en
Priority to EP10764306.6A priority patent/EP2420943A4/en
Priority to CN201080016512.7A priority patent/CN102395964B/zh
Publication of WO2010119720A1 publication Critical patent/WO2010119720A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/90335Query processing
    • G06F16/90344Query processing by using string matching techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/35Clustering; Classification
    • G06F16/353Clustering; Classification into predefined classes

Definitions

  • the present invention relates to a text data processing apparatus and program, and more particularly to a technique that enables statistical analysis processing on text data by classifying the text data by a category that is a nominal measure.
  • Text mining is the division of unformatted text data (normal natural sentences) into words, phrases, etc., and analysis of their appearance frequency and correlation, etc. This is a technique for extracting the above.
  • this text mining requires users to have advanced statistical analysis knowledge, this is an impediment to popularization.
  • interactive analysis a cycle of analysis
  • OLAP online analytical processing
  • OLAP refers to the concept of a system in which a user analyzes a database multidimensionally and visualizes the results.
  • a category-specific axis such as a region or a product is set, and a dice for comparing the analysis results by exchanging the axes, and a time-series transition of data related to a certain category are analyzed.
  • This operation is performed by repeating operations such as “slice”, “drill-down” in which data of hierarchical categories are drilled down and analyzed in stages, and “drill-up” that is analysis in the opposite direction to the drill-down.
  • the characteristic of OLAP is that the user who thinks that analysis is necessary directly manipulates data dynamically through trial and error.
  • Patent Document 1 provides a method for adapting text data to the OLAP framework.
  • the excellent analysis capability of OLAP can be utilized for the analysis of text data.
  • the RDB can freely select and extract data to be analyzed by generating an arbitrary SQL (Structured Query) Language statement.
  • An OLAP framework that performs atypical analysis using such RDB properties is called atypical OLAP.
  • the technique of Patent Document 1 is a technique for adapting text data to an atypical OLAP framework. For this reason, it is also possible to perform statistical analysis by selecting an arbitrary combination from a plurality of structure data constituting the RDB including the structure data categorized from the text data.
  • Text data can be categorized freely in an interactive manner, and can be easily and quickly repeated through trial and error analysis.
  • the purpose is to provide analytical methods.
  • the present invention analyzes whether a character string included in text data matches any of the member character strings given as parameters, and the matched member character string belongs to Get the category string given as a parameter of the nominal scale of the category. Then, the acquired category character string is integrated into a relational database.
  • a category character string converted from text data can be arbitrarily changed according to a parameter.
  • the member character string of the category used for matching determination when converting the text data into the category character string can be arbitrarily changed according to the parameter. Therefore, text data can be freely categorized interactively while changing the category character string and the member character string belonging to the category by trial and error.
  • the analysis operation for the relational database including the category character string as one of the items should be performed interactively and on a trial and error basis. Can do. As a result, trial and error analysis of text data can be repeated easily and quickly.
  • FIG. 1 It is a block diagram which shows the function structural example of the text data processing apparatus by this embodiment. It is a figure which shows the example of the base table stored in RDB. It is a figure which shows the result of having categorized text data according to the SQL sentence of Example 1.
  • FIG. It is a figure which shows the temporary table (category table
  • FIG. It is a figure which shows the table
  • FIG. It is a figure which shows the example of the base table stored in RDB. It is a figure which shows the result of having categorized text data according to the SQL sentence of Example 1.
  • FIG. It is a figure which shows the temporary table (category table
  • FIG. 1 It is a figure which shows the temporary table (category table) produced
  • FIG. It is a figure which shows the table
  • FIG. It is a figure which shows the result of having performed the grouping calculation according to the SQL sentence of Example 3.
  • FIG. It is a figure which shows the temporary table (category table) produced
  • FIG. It is a figure which shows the table
  • FIG. It is a figure which shows the result of having performed the grouping operation according to the SQL sentence of Example 4.
  • FIG. 1 is a block diagram illustrating a functional configuration example of the text data processing apparatus according to the present embodiment.
  • the text data processing apparatus 10 of the present embodiment includes a parameter setting unit 1, a categorization unit 2, and an integration unit 3 as its functional configuration.
  • the integration unit 3 includes a temporary table generation unit 11 and a table combination unit 12.
  • the text data processing apparatus 10 of the present embodiment interactively converts text data stored in a relational database (RDB 30) while a user sets arbitrary parameters through operation of the operation unit 20. Provides means for trial and error analysis.
  • RDB 30 relational database
  • the parameter setting unit 1 sets a category character string representing one or more arbitrary categories and a member character string representing one or more elements belonging to the category as parameters. Specifically, the parameter setting unit 1 sets one or more category character strings and one or more member character strings input through the operation of the operation unit 20 such as a keyboard and a mouse as arguments used in functions to be described later. To do. In parameter setting, one or more members can be included in one category, and one or more sets of such categories and one or more members can be set.
  • the categorizing unit 2 uses the parameter setting in the character string included in the text data stored for each record indicated by the record identifier (RID) in the base table of the RDB 30 (the table before the integration process is performed by the integration unit 3). It is analyzed whether or not any of the member character strings set by the section 1 is matched, and a category character string that is a nominal measure of the matched member character string is obtained for each record.
  • RID record identifier
  • the categorizing unit 2 determines that the character string “damaged” included in a part of the text data matches the member character string “damaged” set by the parameter setting unit 1, and the matched member characters Get the category string "claim” which is the nominal measure of the column.
  • the categorizing unit 2 similarly performs the categorization processing of the text data for the other RID records.
  • the categorization unit 2 realizes the categorization process for converting the text data into the category character string as described above by introducing the TEXT_CLASSIFY function (corresponding to the first function of the present invention) devised by the present applicant.
  • This TEXT_CLASSIFY function searches the text data stored in the base table for each record in the base table of the RDB 30, and if the character string included in the text data matches one of one or more member character strings, the match
  • the function is defined to return a list of one or more category character strings, which are nominal measures of the member character strings, separated by a delimiter (delimiter).
  • the integration unit 3 integrates the category character string acquired for each record by the categorization unit 2 into the base table of the RDB 30.
  • the category character string integration process can be performed by a projecting operation or a combining operation, which is a relational operation of a relational database.
  • a general projecting operation is an operation in which only necessary columns are specified from a table and data of the specified column is extracted from the table.
  • the category character string of each record acquired by executing the TEXT_CLASSIFY function is extracted, so that the category acquired for each record by the categorizing unit 2
  • the character string is integrated into the base table of the RDB 30.
  • the join operation is an operation for generating one table from a plurality of tables.
  • the temporary table generating unit 11 and the table combining unit 12 are used.
  • the temporary table generating unit 11 generates a temporary table by storing the category character string acquired for each record by the categorizing unit 2 together with the RID.
  • the table joining unit 12 joins the temporary table generated by the temporary table generating unit 11 and the base table of the RDB 30 using the RID as a key.
  • the temporary table generation unit 11 realizes the process of generating a temporary table from the category character string as described above by introducing the TEXT_EXTRACT function (corresponding to the second function of the present invention) devised by the present applicant.
  • the TEXT_EXTRACT function is a function defined to store a list of one or more category character strings enumerated by delimiters in the row direction (each record in the temporary table) together with the RID.
  • Each functional configuration block of the text data processing apparatus 10 according to the present embodiment described above can be realized by any of a hardware configuration, a DSP, and software.
  • the text data processing apparatus 10 of the present embodiment is actually configured with a computer CPU or MPU, RAM, ROM, etc., and a program stored in the RAM or ROM operates. realizable.
  • FIG. 2 is a diagram illustrating an example of a base table stored in the RDB 30.
  • the example shown in FIG. 2 is an inquiry information table showing the contents of an inquiry received from a plurality of consumers, and one inquiry content is stored in one record.
  • Each record includes RID, region, name, purchased product, inquiry content, and inquiry date as attribute items.
  • the inquiry content is an attribute item in which a natural sentence freely written by a consumer is stored as text data.
  • the text data stored in the attribute item of the inquiry content is categorized into a nominal scale and analyzed. At that time, by using the TEXT_CLASSIFY function and the TEXT_EXTRACT function as appropriate, various analyzes as described below can be performed on a trial and error basis.
  • Example 1 Example of creating a group projection sequence using the TEXT_CLASSIFY function
  • An example of an SQL statement in this case is shown below.
  • SELECT TEXT_CLASSIFY (---- (1) Inquiry information table.Inquiry contents, ---- (2) 'Claim': ['damaged', 'mixed', 'odd', 'color'], ---- (3) 'Foreign matter': ['bug', 'trash', 'metal', 'hair'], ---- (4) 'Others') group, ---- (5) RID, region, name, purchased product, inquiry contents, inquiry date ---- (6) FROM query information table ---- (7)
  • the meanings of the lines (1) to (7) of the SQL statement are as follows. (1) Specify the TEXT_CLASSIFY function for line unit processing in the first projection column. Line-by-line processing means that processing is performed for each record. (2) As the first argument, specify “inquiry content” which is a text data item of “inquiry information table” (base table). (3) Specify the first set of categories as the second argument. The category is 'Claim' and the member group is defined as ['damaged', 'mixed', 'odd', 'color']. (4) Specify the second set of categories as the third argument.
  • the category is 'foreign matter', and the group of members is defined as ['insect', 'trash', 'metal', 'hair'].
  • (5) Specify the exception category as the fourth argument. Also, specify “Group” as an alternative item name for the TEXT_CLASSIFY function specified in the first projection column.
  • the exception category is defined as 'Other'.
  • the exception category refers to a category that is substituted when the character string included in the text data does not correspond to any member belonging to the category defined in the lines (3) and (4).
  • (7) Specify "query information table" (base table) as the table reference.
  • lines (1) to (5) are used to convert the text data of “inquiry contents” into a category character string using the TEXT_CLASSIFY function, and obtain this as data of a new attribute item “group”. Means.
  • the remaining lines of the SQL statement are the query information table specified in line (7), including the attribute item data “group” obtained by the TEXT_CLASSIFY function and the data of each attribute item specified in line (6). This means that it is extracted as data of each column.
  • FIG. 3 shows the execution result of this SQL statement.
  • the character string “mixed” included in the text data matches the character string “mixed” in the member defined as the second argument in the row (3).
  • the character string “metal” included in the text data matches the character string “metal” in the member defined as the third argument in the row (4).
  • the category character string “claim” is used as the nominal measure for the member character string “mixed”
  • the category character “foreign” is used as the nominal measure for the member character string “metal”.
  • the columns are acquired and integrated into the base table as data of the second record of the new attribute item “group” in the first projection column.
  • the category character string is acquired by the same process and is integrated into the base table as data of a new attribute item “group” in the first projection column.
  • the text data stored in the attribute item of “inquiry content” is a sentence (natural sentence) “It was difficult to peel off the seal”.
  • Example 2 Example of creating a one-dimensional category aggregation table with the TEXT_CLASSIFY function and the TEXT_EXTRACT function
  • the meanings of the lines (1) to (13) of the SQL statement are as follows. (1) Specify “Category Table.Group 1” in the projection column and “Group 1” in the alternative item name. Also, the RID deduplication specification COUNT function, and “Appearance frequency” specified for the alternative item name. (2) Specify "query information table” (base table) in the first table of the table reference. (3) The TEXT_EXTRACT function is specified for the second table in the table reference. (4) “Query information table” (base table) is specified as the first argument of the TEXT_EXTRACT function. (5) Specify the record identifier (RID) of the query information table as the second argument of the TEXT_EXTRACT function.
  • RID record identifier
  • the combined item name of the TEXT_EXTRACT function is automatically the same name (RID).
  • (6) Specify the TEXT_CLASSIFY function as the third argument of the TEXT_EXTRACT function.
  • (7) to (10) The first argument to the fourth argument of the TEXT_CLASSIFY function are the same as the first argument to the fourth argument in “Example 1.
  • "Group 1" is specified as an alternative item name for the return value.
  • the table reference alternative name for the TEXT_EXTRACT function is specified as “category table”.
  • (12) Specify that the query information table and the category table are internally joined by RID.
  • (13) Specify to perform grouping operation with “category table.group 1” for the combined result table.
  • processing starts from the evaluation of the table reference in the FROM clause.
  • a TEXT_EXTRACT function as a table reference function
  • a TEXT_CLASSIFY function as a row unit processing function.
  • the temporary table generation unit 11 executes a table reference process of the TEXT_EXTRACT function using the return value of the TEXT_CLASSIFY function as an argument. That is, the temporary table generation unit 11 executes row-based processing (query information table, RID, ['group 1']) related to table reference.
  • the RID of the query information table, and the category character string that is the return value of the TEXT_CLASSIFY function indicated by the attribute item “Group 1” are paired and inserted into each record of the temporary table. Means to do with.
  • processing of the TEXT_EXTRACT function is completed, and a temporary table is completed.
  • the temporary table returned by the TEXT_EXTRACT function can be referred to by the table reference alternative name “category table” specified in the row (11).
  • the temporary table (category table) generated by the temporary table generating unit 11 is as shown in FIG.
  • the line (12) of the SQL statement represents the processing of the table joining unit 12.
  • the table joining unit 12 internally joins the base table (inquiry information table in FIG. 2) of the RDB 30 and the temporary table (category table in FIG. 4) generated by the temporary table generating unit 11 by RID.
  • the table of the result of the internal combination is as shown in FIG.
  • line (13) of the SQL statement means that the grouping operation indicated by line (1) is executed.
  • the grouping operation shown in this example is to count the frequency of appearance of each category indicated by the attribute item “group 1” in the category table portion of the internal join table generated by the table join unit 12.
  • the execution result of this grooving calculation is as shown in FIG.
  • Example 3 Example of creating a two-dimensional category aggregation table by using the TEXT_CLASSIFY and TEXT_EXTRACT functions (equivalent to drill-down)
  • An example of an SQL sentence in this case is shown below.
  • the meanings of the lines (1) to (17) in the SQL statement are as follows. (1) Specify “Category Table.Group 1” in the first projection column and “Group 1” in the alternative item name. Also, specify “Category Table.Group 2” in the second projection column and “Group 2” in the alternative item name. In addition, the COUNT function that specifies RID deduplication, and “Appearance frequency” are specified for the alternative item name. (2) Specify “query information table” (base table) in the first table of the table reference. (3) The TEXT_EXTRACT function is specified for the second table in the table reference. (4) “Query information table” (base table) is specified as the first argument of the TEXT_EXTRACT function.
  • the temporary table (category table) generated by the temporary table generation unit 11 according to the TEXT_EXTRACT function in the row (6) based on these two category lists is as shown in FIG.
  • the inner join result table generated by the table joiner 12 based on the SQL statement shown in the row (16) that is, the base table (query information table in FIG. 2) of the RDB 30, and the temporary table generator 11
  • FIG. 8 shows a table that is a result of internally joining the temporary table (category table of FIG. 7) with the RID.
  • the internal combination is performed in a state where the category indicated by the attribute item “group 1” is narrowed down to only “claim”.
  • the result of executing the grouping operation indicated by line (1) based on the SQL statement indicated by line (17) is as shown in FIG.
  • the grouping operation indicated by the row (1) is performed in the category indicated by the attribute item “group 1” in the category table portion of the inner join table shown in FIG.
  • the frequency of occurrence is counted for each different combination of the category indicated by “group 2” and the category indicated by the attribute item “group 2”.
  • Example 4 Example of creating a three-dimensional category aggregation table by using the TEXT_CLASSIFY and TEXT_EXTRACT functions (equivalent to drill-down) An example of an SQL sentence in this case is shown below.
  • SELECT Category table Group 1 Group 1, Category table.
  • the meanings of the lines (1) to (20) of the SQL statement are as follows. (1) Specify “Category Table.Group 1” in the first projection column and “Group 1” in the alternative item name. Specify “Category Table.Group 2” in the second projection column and “Group 2” in the alternative item name. In addition, “Category Table.Group 3” is specified in the third projection column, and “Group 3” is specified in the alternative item name. In addition, the COUNT function that specifies RID deduplication, and “Appearance frequency” are specified for the alternative item name. (2) to (14) Same as rows (2) to (14) in “Example 3. Example of creating a narrowed two-dimensional category aggregate table with TEXT_CLASSIFY function and TEXT_EXTRACT function”.
  • the temporary table (category table) generated by the temporary table generation unit 11 according to the TEXT_EXTRACT function in the row (6) based on these three category lists is as shown in FIG.
  • the inner join result table generated by the table joiner 12 based on the SQL statement shown in the row (19), that is, the base table of the RDB 30 (query information table in FIG. 2) and the temporary table generator 11 FIG. 11 shows a table that is a result of internal joining of the temporary table (category table in FIG. 10) with the RID.
  • the internal combination is performed in a state where the category indicated by the attribute item “Group 1” is “claim” and the category indicated by the attribute item “Group 2” is “foreign matter”. .
  • the result of executing the grouping operation indicated by row (1) based on the SQL statement indicated by row (20) is as shown in FIG.
  • the grouping operation shown in this row (1) is performed by the category (in this example, 'claim' in the category table portion of the internal join table shown in FIG. And the category indicated by the attribute item “group 2” (in this example, only the category “foreign matter”) and each category indicated by the attribute item “group 3”. The frequency of appearance is counted for each different combination.
  • the character string included in the text data of the base table of the relational database matches any of the member character strings of the category given as a parameter in the TEXT_CLASSIFY function.
  • the category character string given as a nominal scale parameter in the TEXT_CLASSIFY function is obtained for the matched member character string.
  • the acquired category character string is integrated into the base table.
  • a temporary table is generated using the TEXT_EXTRACT function, and the temporary table and base table can be integrated.
  • the category character string converted from the text data can be arbitrarily changed according to the parameter.
  • the member character string of the category used for matching determination when converting the text data into the category character string can be arbitrarily changed according to the parameter. Therefore, text data can be freely categorized interactively while changing the category character string and the member character string belonging to the category by trial and error.
  • a conventional atypical OLAP operation framework for typical character item data, numerical item data, date item data, and period item data (hereinafter referred to as attribute data) is used.
  • attribute data a conventional atypical OLAP operation framework for typical character item data, numerical item data, date item data, and period item data
  • the text data can be integrated into the atypical OLAP operation framework, and the atypical OLAP operation can be executed seamlessly on the text data.
  • the atypical OLAP operation can be performed by trial and error while arbitrarily changing the category character string converted from the text data or the member character string belonging to the category as a parameter.
  • an appearance frequency report based on a one-dimensional category as in Example 2 above an appearance frequency report based on a two-dimensional category like Example 3, and an appearance frequency report based on a three-dimensional category like Example 4
  • classification based on a set of arbitrary categories (nominal scale) defined at the time of execution as part of the relational database operation it is possible to freely perform an atypical OLAP operation on text data.
  • an atypical OLAP operation can be freely performed for a combination of attribute data and a category (nominal scale) acquired from text data.
  • the following effective applications are possible.
  • atypical aggregation query that supports an atypical OLAP operation
  • a date item for example, year, year, month, year, week, year, month, day
  • the time series transition of the appearance frequency can be examined for each category set.
  • the date items are drilled down like year, year, month, year, week, year, month, day
  • the time series transition of the appearance frequency for each category group can be traced in detail.
  • the transition of the frequency of appearance for each category pair along with time series items can be detailed. You can also keep track.
  • categorization may be performed on index information generated from the text data.
  • the index information may be a full-text search index generated from text data stored in the base table, or may be generated from the text data stored in the base table by subject extraction processing or dependency processing of natural language processing. It may be an index of the selected category.
  • the present invention is applicable to computer technology that enables statistical analysis processing on text data by classifying the text data according to a category that is a nominal measure.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

 テキストデータに含まれる文字列が、パラメータとして与えられたカテゴリのメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列の名義尺度のパラメータとして与えられたカテゴリ文字列を取得するカテゴリ化部2と、当該取得したカテゴリ文字列をリレーショナルデータベースに統合する統合部3とを備え、テキストデータから変換されるカテゴリ文字列をパラメータによって任意に変えるとともに、テキストデータをカテゴリ文字列に変換する際の一致判定に用いるメンバー文字列もパラメータによって任意に変えながら、テキストデータを対話型にて自由自在にカテゴリ化することができるようにする。

Description

テキストデータ処理装置およびプログラム
 本発明は、テキストデータ処理装置およびプログラムに関し、特に、テキストデータをその名義尺度であるカテゴリで分類することにより、テキストデータを対象として統計的な分析処理を可能にする技術に関するものである。
 従来、アンケートの自由回答、コールセンタやWebサイトに寄せられるユーザからの定性情報、掲示板への書き込みなどを解析することによって、何らかの特徴や傾向を把握したり、顧客や市場のニーズを抽出したり、自社製品への不満点を分析して有効な対処法を検討したりすることが一般的に行われている。このような分析をコンピュータで行う場合、大量の電子化されたテキストデータを分析する処理が必要となる。ところが、テキストデータ自体のままでは、当該テキストデータの集合を特徴付ける有用な情報を抽出したり、統計的な手法で計数するなどして人間にとって有用な情報を得たりすることができない。
 これに対して、テキストマイニングと呼ばれるテキストデータ分析手法が存在する。テキストマイニングとは、定型化されていないテキストデータ(通常の自然文)を単語やフレーズなどに分割し、その出現頻度や相関関係などを解析することで、テキストに込められた意味や一定の知見などを抽出する手法である。ところが、このテキストマイニングは、ユーザに高度な統計解析の知識を要求するため、これが普及の阻害要因となっている。また、テキストマイニングは、処理に相応の準備が必要となるため、対話型にて解析手法を変えて試行錯誤的に行う分析(以下、対話型分析という)のサイクルを迅速に繰り返すことが難しい。
 一般に、対話型分析を行うことが可能な手法として、OLAP(online analytical processing)と呼ばれる手法がある。OLAPは、ユーザがデータベースを多次元的に解析し、その結果を視覚化するシステムの概念を言う。OLAPによる多次元分析は、例えば地域別、製品別といったカテゴリ別の軸を設定し、軸を入れ替えて分析した結果を比較する「ダイス」、あるカテゴリに関するデータの時系列的な推移を分析する「スライス」、階層化されたカテゴリのデータを段階的に掘り下げて分析する「ドリルダウン」、当該ドリルダウンと逆方向の分析である「ドリルアップ」などの操作を繰り返すことで行われる。分析が必要だと考えているユーザ自身が試行錯誤しながら、直接データをダイナミックに操作するのがOLAPの特徴である。
 ただし、テキストデータは、そのままではカテゴリ化されていないため、OLAP操作の対象とならない。これに対して、大量の電子化されたテキストデータの文章を分類(カテゴリ化)し、統計的な処理を可能にする技術が提案されている(例えば、特許文献1を参照)。この特許文献1に記載の技術では、非構造データである自然文のテキスト情報を解釈し、当該テキスト情報を集計処理可能なカテゴリ情報に変換する。そして、そのカテゴリ情報を表形式の構造データに変換し、別のカテゴリに関する構造データを有するリレーショナルデータベース(RDB)に統合する。
 このように、特許文献1では、テキストデータをOLAPの枠組みに適合する方法を提供している。すなわち、OLAPの世界で普及しているRDBにテキストデータのカテゴリ化機能を組み込むことによって、OLAPの優れた分析能力をテキストデータの分析に活用できるようにしている。ここで、RDBは、任意のSQL(Structured Query Language)文を生成することにより、分析の対象とするデータを自由に選んで抽出することが可能である。このようなRDBの性質を利用して非定型の分析を行うOLAPの枠組みは、非定型OLAPと呼ばれる。特許文献1の技術は、テキストデータを非定型OLAPの枠組みに適合するための技術である。このため、テキストデータからカテゴリ化された構造データを含めて、RDBを構成する複数の構造データの中から任意の組み合わせを選んで統計的な分析を行うことも可能である。
特開2006-509307号公報
 しかしながら、上記特許文献1に記載の技術では、テキストデータから変換されるカテゴリ情報がプログラムによって固定されている。すなわち、テキストデータがカテゴリ化されてRDBに組み込まれた後は、その組み込まれたデータを用いてRDBの対話型分析を行うことが可能であるが、テキストデータをどのようにカテゴリ化するかという場面においては、対話型にて試行錯誤的に操作をすることができないという問題があった。
 本発明は、このような問題を解決するために成されたものであり、テキストデータを対話型にて自由自在にカテゴリ化でき、簡単かつ迅速に試行錯誤的な分析を繰り返すことのできるテキストデータ分析手法を提供することを目的とする。
 上記した課題を解決するために、本発明では、テキストデータに含まれる文字列が、パラメータとして与えられたメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列が属しているカテゴリの名義尺度のパラメータとして与えられたカテゴリ文字列を取得する。そして、当該取得したカテゴリ文字列をリレーショナルデータベースに統合するようにしている。
 上記のように構成した本発明によれば、テキストデータから変換されるカテゴリ文字列をパラメータによって任意に変えることができる。また、テキストデータをカテゴリ文字列に変換する際の一致判定に用いるカテゴリのメンバー文字列もパラメータによって任意に変えることができる。このため、カテゴリ文字列やカテゴリに属するメンバー文字列を試行錯誤的に変えながら、テキストデータを対話型にて自由自在にカテゴリ化することができる。また、テキストデータから変換されたカテゴリ文字列がリレーショナルデータベースに統合されるので、当該カテゴリ文字列を項目の1つとして含むリレーショナルデータベースに対する分析のための操作も対話型にて試行錯誤的に行うことができる。これにより、テキストデータの試行錯誤的な分析を簡単かつ迅速に繰り返すことが可能となる。
本実施形態によるテキストデータ処理装置の機能構成例を示すブロック図である。 RDBに格納されている元表の例を示す図である。 例1のSQL文に従ってテキストデータをカテゴリ化した結果を示す図である。 例2のSQL文に従って本実施形態の一時表生成部により生成された一時表(カテゴリ表)を示す図である。 例2のSQL文に従って本実施形態の表結合部により一時表と元表とを内部結合した結果の表を示す図である。 例2のSQL文に従ってグルーピング演算を実行した結果を示す図である。 例3のSQL文に従って本実施形態の一時表生成部により生成された一時表(カテゴリ表)を示す図である。 例3のSQL文に従って本実施形態の表結合部により一時表と元表とを内部結合した結果の表を示す図である。 例3のSQL文に従ってグルーピング演算を実行した結果を示す図である。 例4のSQL文に従って本実施形態の一時表生成部により生成された一時表(カテゴリ表)を示す図である。 例4のSQL文に従って本実施形態の表結合部により一時表と元表とを内部結合した結果の表を示す図である。 例4のSQL文に従ってグルーピング演算を実行した結果を示す図である。
 以下、本発明の一実施形態を図面に基づいて説明する。図1は、本実施形態によるテキストデータ処理装置の機能構成例を示すブロック図である。図1に示すように、本実施形態のテキストデータ処理装置10は、その機能構成として、パラメータ設定部1、カテゴリ化部2および統合部3を備えている。統合部3は、一時表生成部11および表結合部12を備えている。本実施形態のテキストデータ処理装置10は、以下に詳しく説明するように、ユーザが操作部20の操作を通じて任意のパラメータを設定しながら、リレーショナルデータベース(RDB30)に格納されているテキストデータを対話型にて試行錯誤的に分析処理する手段を提供する。
 図1において、パラメータ設定部1は、任意の1以上のカテゴリを表すカテゴリ文字列および当該カテゴリに属する1以上の要素を表すメンバー文字列をパラメータとして設定する。具体的には、パラメータ設定部1は、キーボードやマウス等から成る操作部20の操作を通じて入力される1以上のカテゴリ文字列および1以上のメンバー文字列を、後述する関数で使用する引数として設定する。パラメータ設定の際は、1つのカテゴリに対して1以上のメンバーを含ませることが可能であり、そのようなカテゴリと1以上のメンバーのセットを1以上設定することが可能である。
 カテゴリ化部2は、RDB30の元表(統合部3により統合処理が行われる前の表)においてレコード識別子(RID)により示されるレコード毎に格納されたテキストデータに含まれる文字列が、パラメータ設定部1により設定されたメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列の名義尺度であるカテゴリ文字列をレコード毎に取得する。
 例えば、RDB30においてRID=1の第1レコードに格納されているテキストデータが「商品が破損していた」という文章(自然文)であり、パラメータ設定部1によりカテゴリ文字列として「クレーム」が設定されるとともに、そのカテゴリに属するメンバーとして「破損、混入」の2つが設定されたとする。この場合、カテゴリ化部2は、テキストデータの一部に含まれる「破損」という文字列が、パラメータ設定部1により設定された「破損」というメンバー文字列に一致すると判断し、一致したメンバー文字列の名義尺度である「クレーム」というカテゴリ文字列を取得する。カテゴリ化部2は、このようなテキストデータのカテゴリ化処理を他のRIDのレコードについても同様に行う。
 カテゴリ化部2は、上述のようにテキストデータをカテゴリ文字列に変換するカテゴリ化処理を、本出願人が考案したTEXT_CLASSIFY関数(本発明の第1の関数に相当する)の導入によって実現する。このTEXT_CLASSIFY関数は、RDB30の元表のレコード毎に、元表に格納されたテキストデータを検索し、テキストデータに含まれる文字列が1以上のメンバー文字列の何れかと一致した場合に、当該一致したメンバー文字列の名義尺度である1以上のカテゴリ文字列のリストを区切り記号(デリミタ)で区切って返すように定義された関数である。
 統合部3は、カテゴリ化部2によりレコード毎に取得されたカテゴリ文字列をRDB30の元表に統合する。カテゴリ文字列の統合処理は、リレーショナルデータベースの関係演算である射影操作または結合操作によって行うことが可能である。一般的な射影操作は、表の中から必要な列だけを指定して、指定した列のデータを表から取り出す操作である。本実施形態では、元表にある列の各レコードのデータに加えて、TEXT_CLASSIFY関数の実行により取得された各レコードのカテゴリ文字列を取り出すことにより、カテゴリ化部2によりレコード毎に取得されたカテゴリ文字列をRDB30の元表に統合する。
 また、結合操作は、複数の表から1つの表を生成する操作である。結合操作によってカテゴリ文字列の統合処理を行う場合は、一時表生成部11および表結合部12を用いる。一時表生成部11は、カテゴリ化部2によりレコード毎に取得されたカテゴリ文字列をRIDと共に格納することによって一時表を生成する。表結合部12は、一時表生成部11により生成された一時表とRDB30の元表とをRIDをキーとして表結合する。
 一時表生成部11は、上述のようにカテゴリ文字列から一時表を生成する処理を、本出願人が考案したTEXT_EXTRACT関数(本発明の第2の関数に相当する)の導入によって実現する。このTEXT_EXTRACT関数は、デリミタで区切られて列挙された1以上のカテゴリ文字列のリストを行方向(一時表の各レコード)に分けてRIDと共に格納するように定義された関数である。
 以上に説明した本実施形態によるテキストデータ処理装置10の各機能構成ブロックは、ハードウェア構成、DSP、ソフトウェアの何れによっても実現することが可能である。例えばソフトウェアによって実現する場合、本実施形態のテキストデータ処理装置10は、実際にはコンピュータのCPUあるいはMPU、RAM、ROMなどを備えて構成され、RAMやROMに記憶されたプログラムが動作することによって実現できる。
 以下に、上記のように構成した本実施形態によるテキストデータ処理装置10の具体的な動作例を説明する。ここでは、説明の便宜のためにリレーショナルデータベース操作の標準コンピュータ言語であるSQL言語を使用する。ただし、本発明においては、リレーショナル代数モデルに準拠した直交性を有するリレーショナルデータベース操作が必須の要件であって、SQL言語を必須の要件とする訳ではない。
 図2は、RDB30に格納されている元表の例を示す図である。図2に示す例は、複数の消費者から受領した問合せの内容を示す問合せ情報表であり、1つのレコードに1つの問合せ内容が格納されている。各レコードには属性項目としてRID、地域、名前、購入商品、お問合せ内容、お問合せ日が含まれている。このうち、お問合せ内容は、消費者が自由に記載した自然文がテキストデータとして格納される属性項目である。本実施形態では、このお問合せ内容の属性項目に格納されたテキストデータを名義尺度にカテゴリ化して分析する。その際、TEXT_CLASSIFY関数およびTEXT_EXTRACT関数を適宜用いることにより、以下に述べるような様々な分析を試行錯誤的に行うことが可能である。
例1.TEXT_CLASSIFY関数でグループ射影列を作成する例
 この場合におけるSQL文の例を以下に示す。
SELECT 
  TEXT_CLASSIFY( ---- (1)
  問合せ情報表.お問合せ内容, ---- (2)
  'クレーム' : ['破損', '混入', '変', '色'], ---- (3)
  '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (4)
  'その他') グループ, ---- (5)
 RID, 地域, 名前, 購入商品, お問合せ内容, お問合せ日 ---- (6)
FROM 問合せ情報表 ---- (7)
 上記SQL文の各行(1)~(7)の意味は以下の通りである。
(1) 第1射影カラムに行単位処理のTEXT_CLASSIFY関数を指定。行単位処理というのは、レコード毎に処理を行っていくことを意味する。
(2) 第1引数として、「問合せ情報表」(元表)のテキストデータ項目である「お問合せ内容」を指定。
(3) 第2引数としてカテゴリの第1組を指定。カテゴリは'クレーム'、所属メンバーの組は['破損', '混入', '変', '色']と定義。
(4) 第3引数としてカテゴリの第2組を指定。カテゴリは'異物'、所属メンバーの組は['虫', 'ゴミ', '金属', '髪']と定義。
(5) 第4引数として例外カテゴリを指定。また、第1射影カラムで指定したTEXT_CLASSIFY関数の代替項目名として「グループ」を指定。例外カテゴリは'その他'と定義。例外カテゴリとは、テキストデータに含まれる文字列が行(3)(4)で定義されたカテゴリに属する各メンバーの何れにも該当しなかった場合に代替するカテゴリのことを指す。
(6) 第2射影カラム以降は、「問合せ情報表」の各属性項目を指定。
(7) 表参照として「問合せ情報表」(元表)を指定。
 上述のSQL文において、行(1)~(5)は、TEXT_CLASSIFY関数により「お問合せ内容」のテキストデータをカテゴリ文字列に変換し、これを「グループ」という新しい属性項目のデータとして取得することを意味する。SQL文の残りの行は、TEXT_CLASSIFY関数により取得された「グループ」という属性項目のデータと、行(6)で指定される各属性項目のデータとを行(7)で指定された問合せ情報表の各列のデータとして取り出すことを意味する。図3は、このSQL文の実行結果を示す図である。
 図3において、例えば、RID=1の第1レコードにおいて「お問合せ内容」の属性項目に格納されているテキストデータは、「商品が破損していた」という文章(自然文)である。また、このテキストデータに含まれる「破損」という文字列が、行(3)において第2引数として定義されたメンバーの中にある「破損」という文字列と一致する。このため、RID=1の第1レコードにおいては、「破損」というメンバー文字列の名義尺度として「クレーム」というカテゴリ文字列が取得され、最初の列(第1射影カラム)に追加された「グループ」という新しい属性項目の第1レコードのデータとして元表に統合される。
 また、RID=2の第2レコードにおいて「お問合せ内容」の属性項目に格納されているテキストデータは、「金属が中に混入していた」という文章(自然文)である。また、テキストデータに含まれる「混入」という文字列が、行(3)において第2引数として定義されたメンバーの中にある「混入」という文字列と一致する。さらに、このテキストデータに含まれる「金属」という文字列が、行(4)において第3引数として定義されたメンバーの中にある「金属」という文字列と一致する。このため、RID=2の第2レコードにおいては、「混入」というメンバー文字列の名義尺度として「クレーム」というカテゴリ文字列が、「金属」というメンバー文字列の名義尺度として「異物」というカテゴリ文字列が取得され、第1射影カラムの「グループ」という新しい属性項目の第2レコードのデータとして元表に統合される。
 RID=3~6のレコードについても同様の処理によりカテゴリ文字列が取得され、第1射影カラムの「グループ」という新しい属性項目のデータとして元表に統合される。なお、RID=6の第6レコードについては、「お問合せ内容」の属性項目に格納されているテキストデータが「シールがはがれにくかった」という文章(自然文)であり、この中には「クレーム」のカテゴリに属するメンバー文字列も「異物」のカテゴリに属するメンバー文字列も含まれていない。このため、RID=6の第6レコードにおいては、「その他」の例外カテゴリ文字列が取得される。
 すなわち、RID=1~6の各レコードに関して、TEXT_CLASSIFY関数の戻り値であるカテゴリリストは以下の通りとなり、これらの戻り値で示されるカテゴリ文字列が「グループ」という属性項目のデータとして元表に統合される。
 RID=1 戻り値=['クレーム']
 RID=2 戻り値=['クレーム', '異物']
 RID=3 戻り値=['クレーム']
 RID=4 戻り値=['クレーム']
 RID=5 戻り値=['異物']
 RID=6 戻り値=['その他']
例2.TEXT_CLASSIFY関数とTEXT_EXTRACT関数とで1次元カテゴリ集約表を作成する例
 この場合におけるSQL文の例を以下に示す。
SELECT
  カテゴリ表.グループ1 グループ1,
  COUNT(DISTINCT問合せ情報表.RID) 出現度数 ---- (1)
FROM
       問合せ情報表, ---- (2)
    TEXT_EXTRACT( ---- (3)
      問合せ情報表, ---- (4)
      RID, ---- (5)
      TEXT_CLASSIFY( ---- (6)
     問合せ情報表.お問合せ内容, ---- (7)
     'クレーム' : ['破損', '混入', '変', '色'], ---- (8)
           '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (9)
           'その他') グループ1 ---- (10)
   ) カテゴリ表 ---- (11)
WHERE問合せ情報表.RID = カテゴリ表.RID ---- (12)
GROUP BY カテゴリ表.グループ1 ---- (13)
 上記SQL文の各行(1)~(13)の意味は以下の通りである。
(1) 射影カラムに「カテゴリ表.グループ1」、その代替項目名に「グループ1」を指定。また、RIDの重複除去指定のCOUNT関数、その代替項目名に「出現度数」を指定。
(2) 表参照の第1表に「問合せ情報表」(元表)を指定。
(3) 表参照の第2表にTEXT_EXTRACT関数を指定。
(4) TEXT_EXTRACT関数の第1引数として「問合せ情報表」(元表)を指定。
(5) TEXT_EXTRACT関数の第2引数として問合せ情報表のレコード識別子(RID)を指定。TEXT_EXTRACT関数の結合項目名は自動的に同名(RID)となる。
(6) TEXT_EXTRACT関数の第3引数としてTEXT_CLASSIFY関数を指定。
(7)~(10) TEXT_CLASSIFY関数の第1引数から第4引数は、「例1.TEXT_CLASSIFY関数でグループ射影列を作成する例」の第1引数から第4引数と同じ。ただし、返り値の代替項目名として「グループ1」を指定。
(11) TEXT_EXTRACT関数の表参照代替名を「カテゴリ表」と指定。
(12) 問合せ情報表とカテゴリ表をRIDで内部結合するように指定。
(13) 結合した結果表を対象に「カテゴリ表.グループ1」でグルーピング演算するように指定。
 このSQL文では、FROM句における表参照の評価から処理が開始される。この例では、表参照の関数としてTEXT_EXTRACT関数があり、行単位処理の関数としてTEXT_CLASSIFY関数がある。これら2つの関数は、行(3)から行(11)にかけてTEXT_EXTRACT(…,TEXT_CLASSIFY(…)…)の呼び出し関係になっている。カテゴリ化部2は、TEXT_CLASSIFY関数の処理を行単位に実行し、カテゴリリストを戻り値として返す。得られるカテゴリリストは上述の例1の場合と同じである。
 また、一時表生成部11は、TEXT_CLASSIFY関数の戻り値を引数として、TEXT_EXTRACT関数の表参照処理を実行する。すなわち、一時表生成部11は、表参照に関する行単位処理(問合せ情報表, RID, ['グループ1'])を実行する。この表参照処理は、問合せ情報表のRIDと 、属性項目「グループ1」で示されるTEXT_CLASSIFY関数の戻り値であるカテゴリ文字列とを組にして一時表の各レコードに挿入するという処理を行単位で行うことを意味する。ここで、組の第2要素であるカテゴリ文字列が複数の要素(例えば、RID=2の場合の['クレーム', '異物'])を持つ場合は、個々の要素を取り出して、組[問合せ情報表.RID, カテゴリリストの第1要素]、組[問合せ情報表.RID, カテゴリリストの第2要素]の如く独立したレコードとして挿入する。全ての行(レコード)について表参照処理を行うことでTEXT_EXTRACT関数の処理が完了し、一時表が完成する。TEXT_EXTRACT関数が返す一時表は、行(11)で指定される表参照代替名「カテゴリ表」で参照することができる。この例において一時表生成部11により生成される一時表(カテゴリ表)は、図4に示す通りである。
 SQL文の行(12)は、表結合部12の処理を表す。表結合部12は、RDB30の元表(図2の問合せ情報表)と、一時表生成部11により生成された一時表(図4のカテゴリ表)とをRIDで内部結合する。内部結合した結果の表は、図5に示す通りである。また、SQL文の行(13)は、行(1)で示されるグルーピング演算を実行することを意味する。この例で示すグルーピング演算は、表結合部12により生成された内部結合表のうちカテゴリ表の部分において、属性項目「グループ1」で示される各カテゴリの出現度数をカウントするというものである。このグルービング演算の実行結果は、図6に示す通りである。
例3.TEXT_CLASSIFY関数とTEXT_EXTRACT関数とで絞り込み2次元カテゴリ集約表を作成する例(ドリルダウンに相当)
 この場合におけるSQL文の例を以下に示す。
SELECT
  カテゴリ表.グループ1 グループ1,
  カテゴリ表.グループ2 グループ2,
  COUNT(DISTINCT問合せ情報表.RID) 出現度数 ---- (1)
FROM
       問合せ情報表, ---- (2)
  TEXT_EXTRACT( ---- (3)
      問合せ情報表, ---- (4)
      RID, ---- (5)
      TEXT_CLASSIFY( ---- (6)
     問合せ情報表.お問合せ内容, ---- (7)
     'クレーム' : ['破損', '混入', '変', '色'], ---- (8)
     '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (9)
     'その他') グループ1, ---- (10)
      TEXT_CLASSIFY( ---- (11)
     問合せ情報表.お問合せ内容, ---- (12)
     '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (13)
     'その他') グループ2 ---- (14)
  ) カテゴリ表 ---- (15)
WHERE問合せ情報表.RID = カテゴリ表.RID
  AND カテゴリ表.グループ1= 'クレーム' ---- (16)
GROUP BY カテゴリ表.グループ1, カテゴリ表.グループ2 ---- (17)
 上記SQL文の各行(1)~(17)の意味は以下の通りである。
(1) 第1射影カラムに「カテゴリ表.グループ1」、その代替項目名に「グループ1」を指定。また、第2射影カラムに「カテゴリ表.グループ2」、その代替項目名に「グループ2」を指定。さらに、RIDの重複除去指定のCOUNT関数、その代替項目名に「出現度数」を指定。
(2) 表参照の第1表に「問合せ情報表」(元表)を指定。
(3) 表参照の第2表にTEXT_EXTRACT関数を指定。
(4) TEXT_EXTRACT関数の第1引数として「問合せ情報表」(元表)を指定。
(5) TEXT_EXTRACT関数の第2引数として問合せ情報表のレコード識別子(RID)を指定。TEXT_EXTRACT関数の結合項目名は自動的に同名(RID)となる。
(6) TEXT_EXTRACT関数の第3引数としてTEXT_CLASSIFY関数を指定。
(7)~(10) 行(6)に示されるTEXT_CLASSIFY関数の第1引数から第4引数は「例1.TEXT_CLASSIFY関数でグループ射影列を作成する例」の第1引数から第4引数と同じ。ただし、返り値の代替項目名として「グループ1」を指定。
(11) TEXT_EXTRACT関数の第4引数としてTEXT_CLASSIFY関数を指定。
(12) ~(14) 行(11)に示されるTEXT_CLASSIFY関数の第1引数から第3引数は「例1.TEXT_CLASSIFY関数でグループ射影列を作成する例」の第1引数、第3引数、第4引数と同じ。ただし、返り値の代替項目名として「グループ2」を指定。
(15) TEXT_EXTRACT関数の表参照代替名を「カテゴリ表」と指定。
(16) 問合せ情報表とカテゴリ表をRIDで内部結合するように指定。「カテゴリ表.グループ1='クレーム'」で第1次元項目を'クレーム'のみに絞り込むように指定。
(17) 結合した結果表を対象に「カテゴリ表.グループ1」、「カテゴリ表.グループ2」でグルーピング演算するように指定。
 この例において、行(6)に示すTEXT_CLASSIFY関数の戻り値であるカテゴリリストは、以下の通りとなる。
 RID=1 戻り値=['クレーム']
 RID=2 戻り値=['クレーム', '異物']
 RID=3 戻り値=['クレーム']
 RID=4 戻り値=['クレーム']
 RID=5 戻り値=['異物']
 RID=6 戻り値=['その他']
 また、行(11)に示すTEXT_CLASSIFY関数の戻り値であるカテゴリリストは、以下の通りとなる。
 RID=1 戻り値=['その他']
 RID=2 戻り値=['異物']
 RID=3 戻り値=['その他']
 RID=4 戻り値=['その他']
 RID=5 戻り値=['異物']
 RID=6 戻り値=['その他']
 これら2つのカテゴリリストに基づいて行(6)のTEXT_EXTRACT関数に従って一時表生成部11により生成される一時表(カテゴリ表)は、図7に示す通りである。また、行(16)に示すSQL文に基づいて表結合部12により生成される内部結合結果表、つまり、RDB30の元表(図2の問合せ情報表)と、一時表生成部11により生成された一時表(図7のカテゴリ表)とをRIDで内部結合した結果の表は、図8に示す通りである。ここでは、属性項目「グループ1」で示されるカテゴリが'クレーム'となっているもののみに絞り込んだ状態で内部結合が行われている。
 さらに、行(17)で示すSQL文に基づいて行(1)で示されるグルーピング演算を実行した結果は、図9に示す通りである。この行(1)で示すグルーピング演算は、表結合部12により生成された図8に示す内部結合表のうちカテゴリ表の部分において、属性項目「グループ1」で示されるカテゴリ(この例では'クレーム'というカテゴリのみに絞られている)と属性項目「グループ2」で示される各カテゴリとの異なる組み合わせ毎に、その出現度数をカウントするというものである。
例4.TEXT_CLASSIFY関数とTEXT_EXTRACT関数とで絞り込み3次元カテゴリ集約表を作成する例(ドリルダウンに相当する)
 この場合におけるSQL文の例を以下に示す。
SELECT
  カテゴリ表.グループ1 グループ1,
  カテゴリ表.グループ2 グループ2,
  カテゴリ表.グループ3 グループ3,
COUNT(DISTINCT問合せ情報表.RID) 出現度数 ---- (1)
FROM
  問合せ情報表, ---- (2)
  TEXT_EXTRACT( ---- (3)
   問合せ情報表, ---- (4)
   RID, ---- (5)
   TEXT_CLASSIFY( ---- (6)
    問合せ情報表.お問合せ内容, ---- (7)
    'クレーム' : ['破損', '混入', '変', '色'], ---- (8)
    '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (9)
    'その他') グループ1, ---- (10)
   TEXT_CLASSIFY( ---- (11)
    問合せ情報表.お問合せ内容, ---- (12)
    '異物' : ['虫', 'ゴミ', '金属', '髪'], ---- (13)
    'その他') グループ2, ---- (14)
   TEXT_CLASSIFY( ---- (15)
    問合せ情報表.お問合せ内容, 
    '虫' : ['虫'],
    'ゴミ’ : [‘ゴミ’],
    '金属' : ['金属'],
    '髪' : ['髪'], ---- (16)
    'その他') グループ3 ---- (17)
   ) カテゴリ表 ---- (18)
WHERE問合せ情報表.RID = カテゴリ表.RID
  AND カテゴリ表.グループ1= 'クレーム' 
  AND カテゴリ表.グループ2= '異物' ---- (19)
GROUP BY
  カテゴリ表.グループ1,
  カテゴリ表.グループ2,
  カテゴリ表.グループ3 ---- (20)
 上記SQL文の各行(1)~(20)の意味は以下の通りである。
(1) 第1射影カラムに「カテゴリ表.グループ1」、その代替項目名に「グループ1」を指定。第2射影カラムに「カテゴリ表.グループ2」、その代替項目名に「グループ2」を指定。また、第3射影カラムに「カテゴリ表.グループ3」、その代替項目名に「グループ3」を指定。さらに、RIDの重複除去指定のCOUNT関数、その代替項目名に「出現度数」を指定。
(2)~(14) 「例3.TEXT_CLASSIFY関数とTEXT_EXTRACT関数とで絞り込み2次元カテゴリ集約表を作成する例」の行(2)~(14)と同じ。
(15) TEXT_EXTRACT関数の第4引数としてTEXT_CLASSIFY関数を指定。
(16) グループ2のメンバーを展開できるように、行(15)で示されるTEXT_CLASSIFY関数の各引数をカテゴリとメンバーとが同一となるように指定。
(17) 行(15)で示されるTEXT_CLASSIFY関数の代替項目名に「グループ3」を指定。
(18) TEXT_EXTRACT関数の表参照代替名を「カテゴリ表」と指定。
(19) 問合せ情報表とカテゴリ表をRIDで内部結合するように指定。「カテゴリ表.グループ1= 'クレーム'」で第1次元項目を'クレーム'のみに絞り込み、かつ、「カテゴリ表.グループ2= '異物'」で第2次元項目を'異物'のみに絞り込むように指定。
(20) 結合した結果表を対象に「カテゴリ表.グループ1」、「カテゴリ表.グループ2」、「カテゴリ表.グループ3」でグルーピング演算するように指定。
 この例において、行(6)に示すTEXT_CLASSIFY関数の戻り値であるカテゴリリストは、以下の通りとなる。
 RID=1 戻り値=['クレーム']
 RID=2 戻り値=['クレーム', '異物']
 RID=3 戻り値=['クレーム']
 RID=4 戻り値=['クレーム']
 RID=5 戻り値=['異物']
 RID=6 戻り値=['その他']
 また、行(11)に示すTEXT_CLASSIFY関数の戻り値であるカテゴリリストは、以下の通りとなる。
 RID=1 戻り値=['その他']
 RID=2 戻り値=['異物']
 RID=3 戻り値=['その他']
 RID=4 戻り値=['その他']
 RID=5 戻り値=['異物']
 RID=6 戻り値=['その他']
 また、行(15)に示すTEXT_CLASSIFY関数の戻り値であるカテゴリリストは、以下の通りとなる。
 RID=1 戻り値=['その他']
 RID=2 戻り値=['金属']
 RID=3 戻り値=['その他']
 RID=4 戻り値=['その他']
 RID=5 戻り値=['髪']
 RID=6 戻り値=['その他']
 これら3つのカテゴリリストに基づいて行(6)のTEXT_EXTRACT関数に従って一時表生成部11により生成される一時表(カテゴリ表)は、図10に示す通りである。また、行(19)に示すSQL文に基づいて表結合部12により生成される内部結合結果表、つまり、RDB30の元表(図2の問合せ情報表)と、一時表生成部11により生成された一時表(図10のカテゴリ表)とをRIDで内部結合した結果の表は、図11に示す通りである。ここでは、属性項目「グループ1」で示されるカテゴリが'クレーム'、属性項目「グループ2」で示されるカテゴリが'異物'となっているもののみに絞り込んだ状態で内部結合が行われている。
 さらに、行(20)で示すSQL文に基づいて行(1)で示されるグルーピング演算を実行した結果は、図12に示す通りである。この行(1)で示すグルーピング演算は、表結合部12により生成された図11に示す内部結合表のうちカテゴリ表の部分において、属性項目「グループ1」で示されるカテゴリ(この例では'クレーム'というカテゴリのみに絞られている)と属性項目「グループ2」で示されるカテゴリ(この例では'異物'というカテゴリのみに絞られている)と属性項目「グループ3」で示される各カテゴリとの異なる組み合わせ毎に、その出現度数をカウントするというものである。
 以上詳しく説明したように、本実施形態では、リレーショナルデータベースの元表のテキストデータに含まれる文字列が、TEXT_CLASSIFY関数においてパラメータとして与えられたカテゴリのメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列について、TEXT_CLASSIFY関数において名義尺度のパラメータとして与えられたカテゴリ文字列を取得する。そして、当該取得したカテゴリ文字列を元表に統合するようにしている。また、テキストデータから変換したカテゴリ文字列を元表に統合する際に、TEXT_EXTRACT関数を用いて一時表を生成し、当該一時表と元表とを統合することも可能にしている。
 このように構成した本実施形態によれば、テキストデータから変換されるカテゴリ文字列をパラメータによって任意に変えることができる。また、テキストデータをカテゴリ文字列に変換する際の一致判定に用いるカテゴリのメンバー文字列もパラメータによって任意に変えることができる。このため、カテゴリ文字列やカテゴリに属するメンバー文字列を試行錯誤的に変えながら、テキストデータを対話型にて自由自在にカテゴリ化することができる。
 また、テキストデータから変換されたカテゴリ文字列がリレーショナルデータベースに統合されるので、当該カテゴリ文字列を属性項目の1つとして含むリレーショナルデータベースに対する分析(上述のグルーピング演算など)のための操作も対話型にて試行錯誤的に行うことができる。これにより、テキストデータの試行錯誤的な分析を簡単かつ迅速に繰り返すことが可能となる。
 つまり、本実施形態によれば、定型的な文字項目データ、数値項目データ、日付項目データ、期間項目データ(以下、これらを属性データと呼ぶ)を対象とする従来の非定型OLAP操作の枠組みを崩すことなく、テキストデータを非定型OLAP操作の枠組みに統合し、テキストデータを対象として非定型OLAP操作をシームレスに実行することができる。このとき、テキストデータから変換するカテゴリ文字列や、カテゴリに属するメンバー文字列をパラメータとして任意に変えながら、非定型OLAP操作を試行錯誤的に行うことができる。
 例えば、上述の例2のような1次元のカテゴリによる出現度数のレポート、例3のような2次元のカテゴリによる出現度数のレポート、例4のような3次元のカテゴリによる出現度数のレポートの如く、実行時に定義する任意のカテゴリ(名義尺度)の組による分類をリレーショナルデータベース操作の一部として実行することによって、テキストデータを対象に自由自在に非定型OLAP操作を行うことができる。具体的な例は示していないが、属性データとテキストデータから取得したカテゴリ(名義尺度)との組み合わせを対象として自由自在に非定型OLAP操作を行うこともできる。
 リレーショナルデータベース操作の一部としてテキストデータのカテゴリ化の機能を備えた本実施形態では、以下のような効果的な応用も可能になる。例えば、非定型OLAP操作を支える非定型集約クエリーにおいて、グルーピング演算の集約キーとしてカテゴリの組と日付項目(例えば、年、年月、年月週、年月日など)とを指定することにより、カテゴリの組毎に出現度数の時系列推移を調べることができる。このとき、日付項目を年、年月、年月週、年月日の如くドリルダウンしていけば、カテゴリの組毎における出現度数の時系列推移を細かく追跡していくことができる。さらに、テキストデータを対象にカテゴリの組を複数定義し、粒度の粗いカテゴリの組から粒度の細かいカテゴリの組へドリルダウンすることによって、時系列項目と共にカテゴリの組毎における出現度数の推移を細かく追跡していくこともできる。
 具体的には、昨今話題となった食品偽装問題などの予兆をできるだけ早期に発見したいというケースを考える。この場合、お客様相談センターなどに寄せられるクレームのテキストデータの集合を調査対象として、過去の経験から分かっているリスクの高いクレームのカテゴリを粗い粒度の組から細かい粒度の組へ複数定め、カテゴリの組毎に日々の時系列出現度数の変化をモニタすればよい。例えば、ある日を境に出現度数が急に上がり始めたり下がり始めたりした場合には、何らかの予兆の疑いがある。このとき、上述したカテゴリの組と日付項目による非定型OLAP操作が予兆の発見に威力を発揮する。
 なお、上記実施形態では、RDB30の元表に格納されているテキストデータを対象としてカテゴリ化を行う例について説明したが、本発明はこれに限定されない。例えば、RDB30の元表に格納されたテキストデータに代えて、当該テキストデータから生成されたインデックス情報を対象としてカテゴリ化を行うようにしても良い。インデックス情報は、元表に格納されたテキストデータから生成した全文検索用のインデックスであっても良いし、元表に格納されたテキストデータから自然言語処理の主題抽出処理や係り受け処理などによって生成したカテゴリのインデックスであっても良い。
 また、上記実施形態では、テキストデータをカテゴリ化するのにTEXT_CLASSIFY関数を用いる例について説明したが、本発明はこれに限定されない。テキストデータからカテゴリを抽出できるならば、その具体的な方法は問わない。
 また、上記実施形態では、テキストデータの非定型OLAP操作の例として4つの例を挙げたが、これ以外の非定型OLAP操作を行うことができることは言うまでもない。
 その他、上記実施形態は、何れも本発明を実施するにあたっての具体化の一例を示したものに過ぎず、これによって本発明の技術的範囲が限定的に解釈されてはならないものである。すなわち、本発明はその精神、またはその主要な特徴から逸脱することなく、様々な形で実施することができる。
 本発明は、テキストデータをその名義尺度であるカテゴリで分類することにより、テキストデータを対象として統計的な分析処理を可能にするコンピュータ技術に利用可能である。

Claims (6)

  1. 任意の1以上のカテゴリを表すカテゴリ文字列および当該カテゴリに属する1以上の要素を表すメンバー文字列をパラメータとして設定するパラメータ設定手段と、
     リレーショナルデータベースの元表においてレコード識別子により示されるレコード毎に格納されたテキストデータに含まれる文字列が、上記パラメータ設定手段により設定されたメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列の名義尺度であるカテゴリ文字列を上記レコード毎に取得するカテゴリ化手段と、
     上記カテゴリ化手段により上記レコード毎に取得されたカテゴリ文字列を上記リレーショナルデータベースの元表に統合する統合手段とを備えたことを特徴とするテキストデータ処理装置。
  2. 上記統合手段は、上記カテゴリ化手段により上記レコード毎に取得されたカテゴリ文字列を上記レコード識別子と共に格納して一時表を生成する一時表生成手段と、
     上記一時表生成手段により生成された一時表と上記元表とを表結合する表結合手段とを備えたことを特徴とする請求項1に記載のテキストデータ処理装置。
  3. 上記カテゴリ化手段は、上記元表の上記レコード毎に、上記元表に格納された上記テキストデータを検索し、上記テキストデータに含まれる文字列が1以上の上記メンバー文字列の何れかと一致した場合に、当該一致したメンバー文字列の名義尺度である1以上のカテゴリ文字列のリストを区切り記号で区切って返すように定義された第1の関数に従って演算を行うことにより、上記テキストデータを上記カテゴリ文字列に変換することを特徴とする請求項1または2に記載のテキストデータ処理装置。
  4. 上記カテゴリ化手段は、上記元表の上記レコード毎に、上記元表に格納された上記テキストデータを検索し、上記テキストデータに含まれる文字列が1以上の上記メンバー文字列の何れかと一致した場合に、当該一致したメンバー文字列の名義尺度である1以上のカテゴリ文字列のリストを区切り記号で区切って返すように定義された第1の関数に従って演算を行うことにより、上記テキストデータを上記カテゴリ文字列に変換するようになされ、
     上記一時表生成手段は、上記区切り記号で区切られて列挙された1以上のカテゴリ文字列を上記一時表の各レコードに分けて上記レコード識別子と共に格納するように定義された第2の関数に従って演算を行うことにより、上記一時表を生成することを特徴とする請求項2に記載のテキストデータ処理装置。
  5. 上記カテゴリ化手段は、上記リレーショナルデータベースの元表に格納された上記テキストデータに代えて、当該テキストデータから生成されたインデックス情報に含まれる文字列が、上記パラメータ設定手段により設定されたメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列の名義尺度であるカテゴリ文字列を上記レコード毎に取得することを特徴とする請求項1に記載のテキストデータ処理装置。
  6. 任意の1以上のカテゴリを表すカテゴリ文字列および当該カテゴリに属する1以上の要素を表すメンバー文字列をパラメータとして設定するパラメータ設定手段、
     リレーショナルデータベースの元表においてレコード識別子により示されるレコード毎に格納されたテキストデータに含まれる文字列が、上記パラメータ設定手段により設定されたメンバー文字列の何れかに一致するか否かを解析し、一致したメンバー文字列の名義尺度であるカテゴリ文字列を上記レコード毎に取得するカテゴリ化手段、および
     上記カテゴリ化手段により上記レコード毎に取得されたカテゴリ文字列を上記リレーショナルデータベースの元表に統合する統合手段としてコンピュータを機能させるためのコンピュータ読み取り可能なプログラム。
PCT/JP2010/052358 2009-04-14 2010-02-17 テキストデータ処理装置およびプログラム WO2010119720A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
US13/263,977 US20120030204A1 (en) 2009-04-14 2010-02-17 Text data processing device and program
EP10764306.6A EP2420943A4 (en) 2009-04-14 2010-02-17 DEVICE AND PROGRAM FOR PROCESSING TEXT DATA
CN201080016512.7A CN102395964B (zh) 2009-04-14 2010-02-17 文档数据处理装置及程序

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2009-098047 2009-04-14
JP2009098047A JP5577497B2 (ja) 2009-04-14 2009-04-14 テキストデータ処理装置およびプログラム

Publications (1)

Publication Number Publication Date
WO2010119720A1 true WO2010119720A1 (ja) 2010-10-21

Family

ID=42982390

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2010/052358 WO2010119720A1 (ja) 2009-04-14 2010-02-17 テキストデータ処理装置およびプログラム

Country Status (5)

Country Link
US (1) US20120030204A1 (ja)
EP (1) EP2420943A4 (ja)
JP (1) JP5577497B2 (ja)
CN (1) CN102395964B (ja)
WO (1) WO2010119720A1 (ja)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108280141A (zh) * 2017-12-29 2018-07-13 金螳螂家装电子商务(苏州)有限公司 一种用于家装电子商务平台的报价数据快速分类存储方法

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11195046A (ja) * 1998-01-05 1999-07-21 Ricoh Co Ltd 文書処理装置
JP2006509307A (ja) 2002-12-06 2006-03-16 アテンシティ コーポレーション 混合データ統合サービスの提供システム及び提供方法
JP2009098047A (ja) 2007-10-18 2009-05-07 Nippon Seiki Co Ltd リード端子接続構造

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11272701A (ja) * 1998-03-23 1999-10-08 Oki Electric Ind Co Ltd 情報抽出装置
US6751600B1 (en) * 2000-05-30 2004-06-15 Commerce One Operations, Inc. Method for automatic categorization of items
US6928426B2 (en) * 2000-12-30 2005-08-09 Intel Corporation Method and apparatus to improve file management
US7430560B1 (en) * 2005-07-22 2008-09-30 X-Engines, Inc. Multi-level compressed lock-up tables formed by logical operations to compress selected index bits
US8140514B2 (en) * 2008-11-26 2012-03-20 Lsi Corporation Automatic classification of defects
US9020943B2 (en) * 2009-01-07 2015-04-28 Oracle International Corporation Methods, systems, and computer program product for automatically categorizing defects

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11195046A (ja) * 1998-01-05 1999-07-21 Ricoh Co Ltd 文書処理装置
JP2006509307A (ja) 2002-12-06 2006-03-16 アテンシティ コーポレーション 混合データ統合サービスの提供システム及び提供方法
JP2009098047A (ja) 2007-10-18 2009-05-07 Nippon Seiki Co Ltd リード端子接続構造

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
MAKOTO NAGAO, SHIZEN GENGO SHORI, 26 April 1996 (1996-04-26), pages 434 - 438, XP008169816 *
See also references of EP2420943A4

Also Published As

Publication number Publication date
EP2420943A1 (en) 2012-02-22
JP5577497B2 (ja) 2014-08-27
CN102395964B (zh) 2014-11-26
US20120030204A1 (en) 2012-02-02
EP2420943A4 (en) 2014-06-18
CN102395964A (zh) 2012-03-28
JP2010250480A (ja) 2010-11-04

Similar Documents

Publication Publication Date Title
Clifton et al. Emerging standards for data mining
US8316012B2 (en) Apparatus and method for facilitating continuous querying of multi-dimensional data streams
US10095766B2 (en) Automated refinement and validation of data warehouse star schemas
CN110851667B (zh) 一种多源头大量数据的整合分析方法及工具
JP2007317188A (ja) データインテリジェント加工システム及びその方法
US11269867B2 (en) Generating data retrieval queries using a knowledge graph
US10599678B2 (en) Input gathering system and method for defining, refining or validating star schema for a source database
KR20170098854A (ko) 보고 생성 방법
Khalili et al. context–lightweight text analytics using linked data
JP2004021445A (ja) テキストデータ分析システム、テキストデータ分析方法およびコンピュータプログラム
US20080208528A1 (en) Apparatus and method for quantitatively measuring the balance within a balanced scorecard
JP5577497B2 (ja) テキストデータ処理装置およびプログラム
Goasdoué et al. An Evaluation Framework For Data Quality Tools.
US20170116306A1 (en) Automated Definition of Data Warehouse Star Schemas
Badre et al. Comparative ease of use of a diagrammatic vs. an iconic query language
Savinov ConceptMix-Self-Service Analytical Data Integration based on the Concept-Oriented Model.
Pulla et al. Open source data quality tools: Revisited
US20220188895A1 (en) Product feature extraction from structured and unstructured texts using knowledge base
Anzum et al. Graphwrangler: An interactive graph view on relational data
Dey et al. Text-driven multi-structured data analytics for enterprise intelligence
Alspaugh et al. Building blocks for exploratory data analysis tools
Shrivastava et al. Graph mining framework for finding and visualizing substructures using graph database
de Spindler et al. Using synchronised tag clouds for browsing data collections
Zhang et al. Nestedcube: Towards online analytical processing on information-enhanced multidimensional network
Rong et al. DBinsight: A Tool for Interactively Understanding the Query Processing Pipeline in RDBMSs

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201080016512.7

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 10764306

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 13263977

Country of ref document: US

WWE Wipo information: entry into national phase

Ref document number: 2010764306

Country of ref document: EP

NENP Non-entry into the national phase

Ref country code: DE