JPWO2014010068A1 - Program, document conversion apparatus, and document conversion method - Google Patents
Program, document conversion apparatus, and document conversion method Download PDFInfo
- Publication number
- JPWO2014010068A1 JPWO2014010068A1 JP2014524560A JP2014524560A JPWO2014010068A1 JP WO2014010068 A1 JPWO2014010068 A1 JP WO2014010068A1 JP 2014524560 A JP2014524560 A JP 2014524560A JP 2014524560 A JP2014524560 A JP 2014524560A JP WO2014010068 A1 JPWO2014010068 A1 JP WO2014010068A1
- Authority
- JP
- Japan
- Prior art keywords
- document
- item
- xbrl
- character string
- subject
- 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
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/10—Office automation; Time management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/80—Information retrieval; Database structures therefor; File system structures therefor of semi-structured data, e.g. markup language structured data such as SGML, XML or HTML
- G06F16/84—Mapping; Conversion
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/93—Document management systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/12—Use of codes for handling textual entities
- G06F40/137—Hierarchical processing, e.g. outlines
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/12—Use of codes for handling textual entities
- G06F40/14—Tree-structured documents
- G06F40/143—Markup, e.g. Standard Generalized Markup Language [SGML] or Document Type Definition [DTD]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/12—Use of codes for handling textual entities
- G06F40/151—Transformation
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- Business, Economics & Management (AREA)
- Health & Medical Sciences (AREA)
- Artificial Intelligence (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- Data Mining & Analysis (AREA)
- Entrepreneurship & Innovation (AREA)
- Human Resources & Organizations (AREA)
- Strategic Management (AREA)
- Databases & Information Systems (AREA)
- General Business, Economics & Management (AREA)
- Economics (AREA)
- Marketing (AREA)
- Operations Research (AREA)
- Quality & Reliability (AREA)
- Tourism & Hospitality (AREA)
- Document Processing Apparatus (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
文書変換装置(1)は、XBRL文書(41)の項目間の階層関係を含む表示ツリー(221)に基づいて、財務報告書(21)に含まれる項目のうちXBRL文書(41)において子を有する項目に対応する項目を検出し、検出した項目である検出項目の内容を分割し、分割された内容を、検出項目に対応するXBRL文書(41)における項目の子項目に対応付け、対応付けられた内容と子項目とを用いて、財務報告書(21)をXBRL文書(41)に変換する。これにより、文書変換装置(1)は、財務報告書(21)の科目を表示ツリー(221)の要素に適切にマッピングできる。Based on the display tree (221) including the hierarchical relationship between items of the XBRL document (41), the document conversion device (1) generates a child in the XBRL document (41) among the items included in the financial report (21). The item corresponding to the item that is included is detected, the content of the detected item that is the detected item is divided, and the divided content is associated with the child item of the item in the XBRL document (41) corresponding to the detected item. The financial report (21) is converted into an XBRL document (41) using the content and child items. Thereby, the document conversion apparatus (1) can appropriately map the subjects of the financial report (21) to the elements of the display tree (221).
Description
本発明は、プログラム、文書変換装置および文書変換方法に関する。 The present invention relates to a program, a document conversion apparatus, and a document conversion method.
XBRL(eXtensible Business Reporting Language)文書による財務諸表を金融庁へ提出することが義務付けられている。XBRL文書とは、例えば財務会計報告に関して、XML(eXtensible Markup Language)をベースにした報告書記述言語であるXBRLで記述された文書である。XBRL文書で用いられる要素(XBRL要素)には階層関係があり、階層関係は階層化文書によって示される。XBRL文書による財務諸表を提出すべき企業は、提出前に、ワープロ文書の財務諸表に含まれる各科目を、XBRL文書で用いられる各要素に対応付けて、XBRL文書を作成する。 It is obliged to submit financial statements in XBRL (eXtensible Business Reporting Language) documents to the Financial Services Agency. An XBRL document is a document described in XBRL, which is a report description language based on XML (eXtensible Markup Language), for example, for financial accounting reports. Elements used in the XBRL document (XBRL elements) have a hierarchical relationship, and the hierarchical relationship is indicated by the hierarchical document. A company that is to submit a financial statement based on an XBRL document creates an XBRL document by associating each subject included in the financial statement of the word processor document with each element used in the XBRL document before submission.
また、テキスト文書の各科目を階層化文書の各要素に対応付けるマッピングエンジンの技術が開示されている。かかる技術では、マッピングエンジンが、テキスト文書の各科目について、予め定められた関係に従った順序での入力を受け付け、入力を受け付けた科目に対応する階層化文書の要素を検索する。 In addition, a mapping engine technology that associates each subject of a text document with each element of a hierarchical document is disclosed. In this technique, the mapping engine accepts input in an order according to a predetermined relationship for each subject of the text document, and searches for an element of the hierarchical document corresponding to the subject that accepted the input.
しかしながら、上述した技術では、テキスト文書の財務諸表からXBRL文書を作成する際、テキスト文書の科目を階層化文書の要素に適切にマッピングすることができない場合があるという問題があった。すなわち、テキスト文書の科目と階層化文書の要素とが1対1に対応していることを前提としているので、1対Nの場合に対応できない。つまり、テキスト文書の1個の科目が階層化文書のN個の要素に対応している場合、マッピングエンジンは、当該科目を階層化文書の該当する要素に適切にマッピングすることができない。 However, the above-described technique has a problem that when an XBRL document is created from a financial statement of a text document, the subject of the text document cannot be properly mapped to the elements of the hierarchical document. That is, since it is assumed that the text document subject and the hierarchical document element have a one-to-one correspondence, the one-to-N case cannot be handled. That is, when one subject of the text document corresponds to N elements of the hierarchical document, the mapping engine cannot appropriately map the subject to the corresponding element of the hierarchical document.
図12〜図14は、テキスト文書の科目を階層化文書の要素に適切にマッピングすることができない例を示す図である。図12は、財務報告書の各科目と科目値の一例を示す図である。図13および図14は、階層化文書の各XBRL要素の関係の一例を示す図である。マッピングエンジンは、図12に示す1個の科目である「報告期間」を、図13に示す階層化文書の「報告期間」にマッピングすることができる。しかしながら、図14に示す階層化文書の「報告期間」には、1つ下の階層に「期」と「開始日」と「終了日」とが存在している。すなわち、1個の科目が3個の要素に対応しているので、マッピングエンジンは、図12に示す1個の科目である「報告期間」を、図14に示す階層化文書の「報告期間」に適切にマッピングすることができない。 12 to 14 are diagrams illustrating examples in which subjects of a text document cannot be appropriately mapped to elements of a hierarchical document. FIG. 12 is a diagram showing an example of each subject and subject value of the financial report. 13 and 14 are diagrams showing an example of the relationship between the XBRL elements of the hierarchical document. The mapping engine can map “reporting period” which is one subject shown in FIG. 12 to “reporting period” of the hierarchical document shown in FIG. However, in the “reporting period” of the hierarchized document shown in FIG. 14, “period”, “start date”, and “end date” exist in the next lower layer. That is, since one subject corresponds to three elements, the mapping engine converts the “reporting period” that is one subject shown in FIG. 12 into the “reporting period” of the hierarchical document shown in FIG. Cannot be mapped properly.
1つの側面では、本発明は、テキスト文書の財務情報からXBRL文書を作成する際、テキスト文書の科目を階層化文書の要素に適切にマッピングすることを目的とする。 In one aspect, an object of the present invention is to appropriately map a subject of a text document to an element of a hierarchical document when an XBRL document is created from financial information of the text document.
一態様のプログラムは、第1の文書から第2の文書に変換するプログラムにおいて、前記第2の文書の項目間の階層関係を含む階層化文書に基づいて、前記第1の文書に含まれる項目のうち前記第2の文書において子を有する項目に対応する項目を検出し、前記検出した項目である検出項目の内容を分割し、前記分割された内容を、前記検出項目に対応する前記第2の文書における項目の子項目に対応付け、前記対応付けられた内容と前記子項目とを用いて、前記第1の文書を前記第2の文書に変換する処理をコンピュータに実行させる。 The program according to one aspect is an item included in the first document based on a hierarchical document including a hierarchical relationship between items of the second document in the program for converting the first document into the second document. In the second document, an item corresponding to an item having a child is detected, the content of the detected item that is the detected item is divided, and the divided content is divided into the second item corresponding to the detected item. The computer is caused to execute a process of converting the first document into the second document using the associated contents and the child items in association with the child items of the items in the document.
一つの態様によれば、テキスト文書の財務情報からXBRL文書を作成する際、テキスト文書の科目を階層化文書の要素に適切にマッピングすることができる。 According to one aspect, when an XBRL document is created from financial information of a text document, the text document subjects can be appropriately mapped to the elements of the hierarchical document.
以下に、本願の開示するプログラム、文書変換装置および文書変換方法の実施例を図面に基づいて詳細に説明する。なお、実施例によりこの発明が限定されるものではない。 Embodiments of a program, a document conversion apparatus, and a document conversion method disclosed in the present application will be described below in detail with reference to the drawings. The present invention is not limited to the embodiments.
[実施例に係る文書変換装置の構成]
図1は、実施例に係る文書変換装置の構成を示す機能ブロック図である。図1に示すように、文書変換装置1は、財務報告書21とXBRL要素の定義体22とマッピング補助情報23とを入力し、XBRL要素の定義体22とマッピング補助情報23とを用いて、財務報告書21をXBRL文書41に変換する。[Configuration of Document Conversion Apparatus According to Embodiment]
FIG. 1 is a functional block diagram illustrating the configuration of the document conversion apparatus according to the embodiment. As shown in FIG. 1, the
財務報告書21は、テキスト形式(ワード形式を含む)で作成された財務諸表であり、科目名と科目値とから表される。なお、財務報告書21のレイアウトの一例については、後述する。
The
XBRL要素の定義体22は、XBRL文書41で用いられる要素(XBRL要素)を定義する定義体であり、表示ツリー221および要素宣言222を有する。ここで、XBRL文書41とは、財務報告に関して、XMLをベースにした報告書記述言語であるXBRLで記述された文書である。XBRL文書41は、タクソノミおよびインスタンスからなる。タクソノミとは、XBRL要素の体系を定義したものであり、スキーマとリンクベースとからなる。スキーマとは、XBRL要素の名前やデータ型等の属性情報を記憶する辞書であり、実施例では要素宣言222に対応する。リンクベースとは、例えばXBRL要素間の親子関係や表示順や表示名等を記述する文書である。そして、インスタンス(XBRLインスタンスともいう)とは、XBRL要素の具体的な値を記述した報告文書である。なお、表示ツリー221および要素宣言222の構成例については、後述する。
The XBRL
マッピング補助情報23は、財務報告書21の科目値をXBRL要素にマッピングする際に用いられる補助情報である。なお、マッピング補助情報23の内容については、後述する。
The mapping
また、文書変換装置1は、記憶部2と、制御部3とを有する。
In addition, the
記憶部2は、例えばフラッシュメモリ(Flash Memory)やFRAM(登録商標)(Ferroelectric Random Access Memory)等の不揮発性の半導体メモリ素子等の記憶装置に対応する。そして、記憶部2は、財務報告書21、XBRL要素の定義体22およびマッピング補助情報23を有する。
The memory |
財務報告書21は、後述する入力部30によって記憶部2に格納される。XBRL要素の定義体22は、後述する入力部30によって記憶部2に格納される。マッピング補助情報23は、後述する入力部30によって記憶部2に格納される。
The
制御部3は、各種の処理手順を規定したプログラムや制御データを格納するための内部メモリを有し、これらによって種々の処理を実行する。そして、制御部3は、例えば、ASIC(Application Specific Integrated Circuit)やFPGA(Field Programmable Gate Array)等の集積回路またはCPU(Central Processing Unit)やMPU(Micro Processing Unit)等の電子回路に対応する。さらに、制御部3は、入力部30と、レイアウト解析部31と、定義体解析部32と、マッピング部33と、出力部34とを有する。
The
入力部30は、財務報告書21を入力し、入力した財務報告書21を記憶部2に格納する。また、入力部30は、XBRL要素の定義体22を入力し、入力したXBRL要素の定義体22を記憶部2に格納する。また、入力部30は、マッピング補助情報23を入力し、入力したマッピング補助情報23を記憶部2に格納する。例えば、入力部30は、財務報告書21、XBRL要素の定義体22、マッピング補助情報23をファイルにより入力する。
The
レイアウト解析部31は、財務報告書21のレイアウトを解析する。例えば、レイアウト解析部31は、財務報告書21を記憶部2から読み出し、読み出した財務報告書21より、XBRL要素にマッピングする科目の名前と値とを取得する。ここで、財務報告書21のレイアウトについて、図2を参照して説明する。図2は、財務報告書の表紙のレイアウトの一例を示す図である。図2に示すように、財務報告書21の表紙には、科目名21aと科目値21bが記述されている。科目名21aは、科目の名前を示す。科目値21bは、科目名に対する値(文字列)を示す。一例として、科目名21aが「提出書類」である場合、科目値21bとして「有価証券報告書」が記述されている。科目名21aが「報告期間」である場合、科目値21bとして「第100期(自 平成22年4月1日 至 平成23年3月31日」が記述されている。
The
定義体解析部32は、XBRL要素の定義体22を解析する。例えば、定義体解析部32は、XBRL要素の定義体22を記憶部2から読み出す。そして、定義体解析部32は、XBRL要素の定義体22の表示ツリー221より、いずれかのXBRL要素にマッピングしようとしている財務報告書21の科目の名前と一致または類似する表示名か要素名を持つXBRL要素を取得する。そして、定義体解析部32は、XBRL要素の定義体22の要素宣言222より、取得したXBRL要素の要素宣言を取得する。ここで、表示ツリー221および要素宣言222の構成について、図3および図4を参照して説明する。
The definition
図3は、表示ツリーの構成の一例を示す図である。図3に示すように、表示ツリー221には、XBRL要素の表示上の要素間の関係がツリー構造で表されている。XBRL要素は、表示名と要素名を使って表される。一例として、表示名が「提出書類」である場合、要素名として「ReportName」が記述されている。このXBRL要素には、子孫関係の要素が存在しない。また、別の例として、表示名が「報告期間」である場合、要素名として「ReportingPeriod」が記述されている。このXBRL要素には、表示名がそれぞれ「期」、「開始日」、「終了日」の子孫関係のXBRL要素が存在している。表示名が「期」である場合、要素名として「StageOfReportingPeriod」が記述されている。表示名が「開始日」である場合、要素名として「StartDateOfReportingPeriod」が記述されている。表示名が「終了日」である場合、要素名として「EndDateOfReportingPeriod」が記述されている。
FIG. 3 is a diagram illustrating an example of a configuration of a display tree. As shown in FIG. 3, the
図4は、要素宣言のデータ構造の一例を示す図である。図4に示すように、要素宣言222には、要素名222bと、抽象要素フラグ222cと、nil値許可フラグ222dと、データ型222eと、制約222fとが対応付けて記憶される。なお、説明の便宜上、要素宣言222には、XBRL要素の表示名であって要素名222bに対応する表示名を表示名222aとして記載するものとする。要素名222bは、XBRL要素の要素名を示す。抽象要素フラグ222cは、具体的な値がマッピングされない抽象要素(見出し)であるか否かを示すフラグである。抽象要素である場合には、例えば「○」が設定され、抽象要素でない場合には、例えば「×」が設定される。nil値許可フラグ222dは、nil値を許可する要素であるか否かを示すフラグである。nil値を許可する要素である場合には、例えば「○」が設定され、nil値を許可しない要素である場合には、例えば「×」が設定される。なお、nil値とは、NULL値(空値)と同義であり、値をもたないことを意味する。データ型222eは、マッピングされる値のデータ型を示す。例えば、文字列の場合には「文字列型」、日付の場合には「日付型」、正の整数の場合には「正の整数型」が設定される。制約222fは、要素にマッピングされる値の書式の制約を示す。例えば、数字3桁と数字4桁をハイフンでつなぐ書式の制約がある場合には、その旨が設定される。
FIG. 4 is a diagram illustrating an example of the data structure of the element declaration. As shown in FIG. 4, in the
一例として、表示名222aが「報告期間」である場合、抽象要素フラグ222cとして「○」、nil値フラグ222dとして「×」、データ型222eとして「文字列型」が設定される。表示名222aが「期」である場合、抽象要素フラグ222cとして「×」、nil値フラグ222dとして「×」、データ型222eとして「正の整数型」が設定される。表示名222aが「開始日」である場合、抽象要素フラグ222cとして「×」、nil値フラグ222dとして「×」、データ型222eとして「日付型」が設定される。
As an example, when the
図1に戻って、マッピング部33は、XBRL要素の定義体22に基づいて、財務報告書21に含まれる科目のうちXBRL文書41において子孫を有する要素に対応する科目を検出する。例えば、マッピング部33は、定義体解析部32によって取得されたXBRL要素の要素宣言に基づいて、XBRL要素が抽象要素であるか否かを判定する。そして、マッピング部33は、XBRL要素が抽象要素であると判定した場合、表示ツリー221のXBRL要素間の親子関係に基づいて、当該XBRL要素が表示ツリー221上で階層化されている、すなわち子孫の要素を有しているか否かを判定する。そして、マッピング部33は、XBRL要素が表示ツリー221上で階層化されていると判定した場合、当該XBRL要素を幾つかの要素から構成された要素と判断する。すなわち、マッピング部33は、当該XBRL要素にマッピングする科目を、その科目値を分割すべき科目として検出する。
Returning to FIG. 1, the
マッピング部33は、XBRL要素の定義体22に基づいて、検出した科目の科目値を分割し、分割した科目値の各値を、対応するXBRL要素の子孫の要素にマッピングする。例えば、マッピング部33は、表示ツリー221から、検出した科目に対応するXBRL要素の子孫要素を、出現順に選択する。そして、マッピング部33は、選択した子孫要素に対応する要素宣言を要素宣言222から取得する。そして、マッピング部33は、取得した要素宣言内のデータ型222eに合致した部分を、検出した科目の科目値から抽出し、抽出した部分を、選択中の子孫要素にマッピングする。ここで、マッピング部33は、データ型222eに合致した部分を科目値から抽出できない場合、選択中の子孫要素がnil値を許可する要素であれば科目値の入力が省略されたと判断する。そして、マッピング部33は、選択中の子孫要素に何もマッピングしない。そして、マッピング部は、代わりに、nil値に関する属性であるnil属性にnil値であることを示す「true」を設定する。なお、nil値を許可する要素であるか否かは、子孫要素の要素宣言内のnil値許可フラグ222dによって判定される。
The
具体例として、図2で示す財務報告書21内の科目「報告期間」を図3で示す表示ツリー221上のXBRL要素「報告期間」へマッピングする場合について説明する。なお、XBRL要素の要素宣言として、図4で示す要素宣言222が用いられるものとする。マッピング部33は、XBRL要素「報告期間」の要素宣言に基づいて、XBRL要素が抽象要素であるか否かを判定する。ここでは、マッピング部33は、図4で示す要素宣言222のうちXBRL要素「報告期間」の要素宣言の抽象要素フラグ222cが「○」であるので、XBRL要素「報告期間」は抽象要素であると判定する。
As a specific example, the case where the subject “reporting period” in the
そして、マッピング部33は、XBRL要素「報告期間」が抽象要素であると判定したので、表示ツリー221のXBRL要素間の親子関係に基づいて、XBRL要素「報告期間」が表示ツリー221上で子孫の要素を持つか否かを判定する。ここでは、マッピング部33は、図3で示す表示ツリー221に基づいて、XBRL要素「報告期間」が3つの子孫の要素「期」、「開始日」、「終了日」を持つと判定する。したがって、マッピング部33は、XBRL要素「報告期間」を3つの要素から構成されていると判断する。すなわち、マッピング部33は、XBRL要素「報告期間」にマッピングする科目「報告期間」を、その科目値を分割すべき科目として検出する。
Then, since the
そして、マッピング部33は、表示ツリー221から、検出した科目「報告期間」に対応するXBRL要素「報告期間」の子孫要素を順番に選択する。ここでは、マッピング部33は、図3で示す表示ツリー221からXBRL要素「報告期間」の子孫要素「期」、「開始日」、「終了日」を順番に選択する。そして、マッピング部33は、検出した科目「報告期間」の科目値から、選択した子孫要素に対応する要素宣言内のデータ型222eに合致した部分を抽出する。そして、マッピング部33は、抽出した部分を、選択した子孫要素にマッピングする。
Then, the
ここでは、図2に示すように、科目名21a「報告期間」の科目値21bが「第100期(自 平成22年4月1日 至平成23年3月31日)」である。そこで、マッピング部33は、科目値21bから、子孫要素「期」のデータ型222e「正の整数型」に合致した部分「100」を抽出する。そして、マッピング部33は、抽出した部分「100」を、子孫要素「期」にマッピングする。以下のタグは、XBRL文書41を出力したときの結果である。
<StageOfReportingPeriod>100</StageOfReportingPeriod>Here, as shown in FIG. 2, the
<StageOfReportingPeriod> 100 </ StageOfReportingPeriod>
また、マッピング部33は、科目値21bから、子孫要素「開始日」のデータ型222e「日付型」に合致した部分「平成22年4月1日」を抽出する。そして、マッピング部33は、抽出した部分を、子孫要素「開始日」にマッピングする。以下のタグは、XBRL文書41を出力したときの結果である。なお、以下の例では、抽出した部分は、和暦から西暦に変換された後マッピングされているものとする。
<StartDateOfReportingPeriod>2010-04-01</StartDateOfReportingPeriod>Further, the
<StartDateOfReportingPeriod> 2010-04-01 </ StartDateOfReportingPeriod>
さらに、マッピング部33は、科目値21bから、子孫要素「終了日」のデータ型222e「日付型」に合致した部分「平成23年3月31日」を抽出する。そして、マッピング部33は、抽出した部分を、子孫要素「終了日」にマッピングする。以下のタグは、XBRL文書41を出力したときの結果である。なお、以下の例では、抽出した部分は、和暦から西暦に変換された後マッピングされているものとする。
<EndDateOfReportingPeriod>2011-03-31</EndDateOfReportingPeriod>Further, the
<EndDateOfReportingPeriod> 2011-03-31 </ EndDateOfReportingPeriod>
別の具体例として、図2で示す財務報告書21内の科目の科目名21a「本店の所在の場所」を図3で示す表示ツリー221上のXBRL要素「本店の所在の場所」へマッピングする場合について説明する。なお、XBRL要素の要素宣言として、図4で示す要素宣言222が用いられるものとする。マッピング部33は、XBRL要素「本店の所在の場所」の要素宣言に基づいて、XBRL要素が抽象要素であるか否かを判定する。ここでは、マッピング部33は、図4で示す要素宣言222のうちXBRL要素「本店の所在の場所」の要素宣言の抽象要素フラグ222cが「○」であるので、XBRL要素「本店の所在の場所」は抽象要素であると判定する。
As another specific example, the
そして、マッピング部33は、XBRL要素「本店の所在の場所」が抽象要素であると判定したので、表示ツリー221のXBRL要素間の親子関係に基づいて、XBRL要素「本店の所在の場所」が表示ツリー221上で子孫の要素を持つか否かを判定する。ここでは、マッピング部33は、図3で示す表示ツリー221に基づいて、XBRL要素「本店の所在の場所」が2つの子孫の要素「郵便番号」、「住所」を持つと判定する。したがって、マッピング部33は、XBRL要素「本店の所在の場所」を2つの要素から構成されていると判断する。すなわち、マッピング部33は、XBRL要素「本店の所在の場所」にマッピングする科目「本店の所在の場所」を、その科目値を分割すべき科目として検出する。
Then, since the
そして、マッピング部33は、表示ツリー221から、検出した科目の科目名21a「本店の所在の場所」に対応するXBRL要素「本店の所在の場所」の子孫要素を順番に選択する。ここでは、マッピング部33は、図3で示す表示ツリー221からXBRL要素「本店の所在の場所」の子孫要素「郵便番号」、「住所」を順番に選択する。そして、マッピング部33は、検出した科目の科目名21a「本店の所在の場所」の科目値21bから、選択した子孫要素に対応する要素宣言内のデータ型222eおよび制約222fに合致した部分を抽出する。そして、マッピング部33は、抽出した部分を、選択した子孫要素にマッピングする。
Then, the
ここでは、図2に示すように、科目の科目名21a「本店の所在の場所」の科目値21bは、「東京都新宿区新宿1丁目1番1号」である。そこで、マッピング部33は、この科目値21bから、子孫要素「郵便番号」のデータ型222e「文字列型」と制約222f「数字3桁“−”数字4桁」に合致した部分の抽出を試みる。ところが、マッピング部33は、科目値から、データ型222eと制約222fに合致した部分を抽出できない。そこで、マッピング部33は、選択した子孫要素「郵便番号」のnil値許可フラグ222dが「○」であるので、子孫要素「郵便番号」がnil値を許可する要素であると判定する。そこで、マッピング部33は、科目値の入力が省略されたと判断して、選択した子孫要素「郵便番号」に何もマッピングしないで、代わりに、nil属性に「true」を設定する。以下のタグは、XBRL文書41を出力したときの、子孫要素「郵便番号」に関する結果である。
<ZipcodeOfCompanyLocation nil=”true”/>Here, as shown in FIG. 2, the
<ZipcodeOfCompanyLocation nil = ”true” />
また、マッピング部33は、科目値から、子孫要素「住所」のデータ型222e「文字列型」に合致した部分「東京都新宿区新宿1丁目1番1号」を抽出する。そして、マッピング部33は、抽出した部分を、子孫要素「住所」にマッピングする。以下のタグは、XBRL文書41を出力したときの結果である。
<AddressOfCompanyLocation>東京都新宿区新宿1丁目1番1号</AddressOfCompanyLocation>Further, the
<AddressOfCompanyLocation> 1-1 1-1 Shinjuku Shinjuku-ku, Tokyo </ AddressOfCompanyLocation>
このようにして、マッピング部33は、財務報告書21からXBRL文書41を作成する際、財務報告書21の科目をXBRL要素間の階層関係を含む表示ツリー221の要素に適切にマッピングすることができる。
In this way, when creating the
出力部34は、マッピング部33によってマッピングされた結果を示すXBRLインスタンスを出力する。実施例では、このXBRLインスタンスがXBRL文書41となる。例えば、出力部34は、マッピング結果であるXBRL文書41をモニタに出力しても良いし、記憶部2に記憶するようにしても良い。
The
ところで、要素宣言222に、XBRL要素のデータ型222eとして制約222fのない文字列型が指定される場合がある。かかる場合に、マッピング部33は、該当する科目値から期待値だけを抽出することができないことがある。一例として、図2で示す財務報告書21内の科目の科目名21a「代表者の役職氏名」の科目値21bを図3で示す表示ツリー221上のXBRL要素「代表者の役職氏名」へマッピングする場合について説明する。マッピング部33は、図3で示す表示ツリー221に基づいて、XBRL要素「代表者の役職氏名」が2つの子孫の要素「役職」と「氏名」を持つと判定する。そして、マッピング部33は、科目名21a「代表者の役職氏名」の科目値21b「代表取締役 日本 太郎」から、子孫要素「役職」のデータ型222e「文字列型」に合致した部分を抽出する。ここでは、マッピング部33は、子孫要素「役職」に応じた期待値として、科目値21bから「代表取締役」を抽出したいところ、科目値21b全体の「代表取締役 日本 太郎」を抽出してしまう。すなわち、マッピング部33は、科目値21bから期待値だけを抽出することができない。
By the way, in the
そこで、文書変換装置1は、科目値21bから抽出したい、XBRL要素に応じた期待値を、マッピング用の補助情報としてマッピング補助情報23−1に予め記憶しておくようにすれば良い。図5Aは、マッピング補助情報のデータ構造の一例を示す図である。図5Aに示すように、マッピング補助情報23−1には、表示名231aと、要素名231bと、期待値の候補231cとが対応付けて記憶される。表示名231aは、XBRL要素の表示名である。要素名231bは、XBRL要素の要素名である。期待値の候補231cは、XBRL要素に応じた期待値の候補を示す。一例として、表示名231aが「役職」である場合、期待値の候補231cとして「代表取締役」、「部長」、「部長代理」、「課長」と記憶している。表示名231aが「氏名」である場合、期待値の候補231cとして「日本 太郎」、「日本 次郎」と記憶している。
Therefore, the
このようなマッピング補助情報23−1を利用して、マッピング部33は、科目値21bからXBRL要素のデータ型222e「文字列型」に合致した部分を抽出する。すなわち、マッピング部33は、マッピング補助情報23−1を利用して、XBRL要素に応じた期待値の候補231cと合致する値を科目値21bから抽出する。ここでは、マッピング部33は、科目値21b「代表取締役 日本 太郎」から、子孫要素「役職」のデータ型222e「文字列型」に合致した部分として、マッピング補助情報23−1を利用して「代表取締役」を抽出できる。また、マッピング部33は、科目値21b「代表取締役 日本 太郎」から、子孫要素「氏名」のデータ型222e「文字列型」に合致した部分として、マッピング補助情報23−1を利用して「日本 太郎」を抽出できる。
Using such mapping auxiliary information 23-1, the
また、マッピング部33が、該当する科目値21bから期待値だけを抽出することができない別の例を以下に示す。図2で示す財務報告書21内の科目の科目名21a「電話番号」の科目値21bを図3で示す表示ツリー221上のXBRL要素「電話番号」へマッピングする場合について説明する。マッピング部33は、科目「電話番号」の科目値21b「111(222)3333(代表)」からデータ型222e「文字列型」に合致した部分を抽出する。ここでは、マッピング部33は、XBRL要素「電話番号」に応じた期待値として、科目値から「111(222)3333」を抽出したいところ、末尾文字の“(代表)”を含んだ「111(222)3333(代表)」を抽出してしまう。すなわち、マッピング部33は、科目値から期待値だけを抽出することができない。ここで、マッピング部33が、科目値21bから「111(222)3333」を抽出するために、要素宣言222の制約222fに抽出したい書式を指定する手段が考えられる。しかしながら、電話番号には、市外局番と市内局番の区切り文字として、様々な区切り文字(例えば、“(”、“)”、“−”、“ ”)がある。したがって、XBRL要素「電話番号」のデータ型222eは、制約222fの指定がない単純な文字列型とせざるを得ない。
Another example in which the
そこで、文書変換装置1は、科目値21bに入る可能性のある不要な文字列を、マッピング用の補助情報としてマッピング補助情報23−2に予め記憶しておくようにすれば良い。言い換えれば、文書変換装置1は、科目値21bから削除する可能性のある文字列を、マッピング補助情報23−2に予め記憶しておく。図5Bは、マッピング補助情報のデータ構造の一例を示す図である。図5Bに示すように、マッピング補助情報23−2には、削除項目232aと、削除候補232bとが対応付けて記憶される。削除項目232aは、科目値21bから削除する可能性のある文字列の項目を示す。削除候補232bは、削除項目に応じた削除する可能性のある文字列を示す。一例として、削除項目232aが「先頭文字列」である場合、削除候補232bとして「〒」、「Tel」と記憶している。削除項目232aが「区切り文字」である場合、削除候補232bとして「.」、「/」と記憶している。削除項目232aが「末尾文字列」である場合、削除候補232bとして「(代表)」、「(直通)」と記憶している。
Therefore, the
このようなマッピング補助情報23−2を利用して、マッピング部33は、科目値21bに削除項目232aに応じた削除候補232bがあれば、科目値21bからその部分を削除する。ここでは、マッピング部33は、科目値21b「111(222)3333(代表)」に削除項目232a「末尾文字列」に応じた「(代表)」があるので、科目値21bからその部分を削除する。この結果、マッピング部33は、マッピング補助情報23−2を利用して、科目値21bから「111(222)3333」を抽出できる。
Using such mapping auxiliary information 23-2, if there is a
[文書変換処理の主処理]
次に、実施例に係る文書変換処理の主処理の手順について、図6を参照して説明する。図6は、実施例に係る文書変換処理の主処理の手順を示すフローチャートである。なお、図6では、ワード形式の財務報告書21に対して、ワード画面上でタグ付けしたい科目の値をXBRL要素にマッピングし、XBRL文書41に変換する場合を説明する。[Main process of document conversion process]
Next, the procedure of the main process of the document conversion process according to the embodiment will be described with reference to FIG. FIG. 6 is a flowchart illustrating the procedure of the main process of the document conversion process according to the embodiment. FIG. 6 illustrates a case where the value of a subject to be tagged on the word screen is mapped to the XBRL element and converted into the
まず、制御部3は、XBRL文書41への文書変換の要求がされたか否かを判定する(ステップS10)。例えば、制御部3は、ワード画面上でタグ付けしたい科目が選択されたか否かを判定することで、XBRL文書41への文書変換の要求がされたか否かを判定する。文書変換の要求がされなかったと判定した場合(ステップS10;No)、制御部3は、文書変換の要求がされるまで、判定処理を繰り返す。
First, the
一方、文書変換の要求がされたと判定した場合(ステップS10;Yes)、入力部30は、財務報告書21を入力し(ステップS11)、記憶部2に格納する。そして、入力部30は、XBRL要素の定義体22を入力し(ステップS12)、記憶部2に格納する。
On the other hand, if it is determined that a document conversion request has been made (step S10; Yes), the
続いて、レイアウト解析部31は、記憶部2から財務報告書21を読み出し、読み出した財務報告書21より、選択された科目の名前(科目名)と値(科目値)を取得する(ステップS13)。
Subsequently, the
そして、定義体解析部32は、記憶部2からXBRL要素の定義体22を読み出し、読み出したXBRL要素の定義体22より、科目の名前に等しいか近い表示名か要素名を持つXBRL要素の定義を取得する(ステップS14)。例えば、定義体解析部32は、表示ツリー221より、XBRL要素にマッピングする科目の名前と一致または類似する表示名か要素名を持つXBRL要素を取得する。そして、定義体解析部32は、要素宣言222より、取得したXBRL要素の要素宣言を取得する。
Then, the definition
続いて、マッピング部33は、取得したXBRL要素の定義である要素宣言を解析し、表示情報およびマッピング補助情報23に応じて、取得した科目値を当該XBRL要素にマッピングする(ステップS15)。なお、表示情報には、表示ツリー221および要素宣言222が含まれる。
Subsequently, the
そして、出力部34は、マッピング部33によってマッピングされた結果、XBRLインスタンス(XBRL文書41)として出力する(ステップS16)。すなわち、出力部34は、XBRLインスタンスを例えば記憶部2に出力する。これにより、文書変換装置1は、財務報告書21をXBRL文書41に変換する文書変換処理を終了する。
Then, the
[マッピング処理の手順]
次に、図6に示すS15におけるマッピング処理の手順について、図7〜図10を参照して説明する。図7〜図10は、実施例に係るマッピング処理の手順を示すフローチャートである。[Mapping procedure]
Next, the procedure of the mapping process in S15 shown in FIG. 6 will be described with reference to FIGS. 7 to 10 are flowcharts illustrating the procedure of the mapping process according to the embodiment.
まず、マッピング部33は、科目値に、マッピング補助情報23に定義された任意の先頭文字列または末尾文字列を含むか否かを判定する(ステップS21)。これは、科目値から不要な文字列を削除するためである。例えば、科目値が「111(222)3333(代表)」である場合に、末尾文字列である「(代表)」を削除する場合である。
First, the
そして、マッピング部33は、科目値に任意の先頭文字列または末尾文字列を含むと判定した場合(ステップS21;Yes)、科目値から、マッピング補助情報23に定義された任意の先頭文字列または末尾文字列を削除する(ステップS22)。すなわち、科目値には、含むと判定された文字列を削除した後の文字列が設定される。そして、マッピング部33は、ステップS23に移行する。一方、マッピング部33は、科目値に任意の先頭文字列および末尾文字列を含まないと判定した場合(ステップS21;No)、ステップS23に移行する。
When the
ステップS23では、マッピング部33は、科目の名前に対応したXBRL要素の要素宣言を解析した結果、当該XBRL要素が抽象要素か否かを判定する(ステップS23)。当該XBRL要素が抽象要素でないと判定した場合(ステップS23;No)、マッピング部33は、科目値を当該XBRL要素に割り当てる(ステップS24)。そして、マッピング部33は、マッピング処理を終了する。
In step S23, the
一方、当該XBRL要素が抽象要素であると判定した場合(ステップS23;Yes)、マッピング部33は、表示ツリー221をトラバースし、当該XBRL要素における末端の子孫要素の表示名および要素名をスタックする(ステップS25)。そして、マッピング部33は、当該XBRL要素が子孫を持つか否かを判定する(ステップS26)。ここでは、マッピング部33は、当該XBRL要素におけるスタックがされたか否かによって、当該XBRL要素が子孫を持つか否かを判定する。そして、当該XBRL要素が子孫を持つと判定した場合(ステップS26;Yes)、マッピング部33は、子孫要素へのマッピング処理を行うべく、ステップS31に移行する。
On the other hand, when it is determined that the XBRL element is an abstract element (step S23; Yes), the
一方、当該XBRL要素が子孫を持たないと判定した場合(ステップS26;No)、マッピング部33は、当該XBRL要素が抽象要素でありながら子孫を持たないので、マッピングエラーを文書変換の要求元へ通知する(ステップS27)。そして、マッピング部33は、マッピング処理を終了する。
On the other hand, if it is determined that the XBRL element does not have a descendant (step S26; No), the
ステップS31では、マッピング部33は、スタックから子孫要素の要素名を取得し(ステップS31)、取得できたか否かを判定する(ステップS32)。ここで、マッピング部33は、取得できなかったと判定した場合(ステップS32;No)、さらに、科目値が空文字列であるか否かを判定する(ステップS33)。科目値が空文字列であると判定した場合(ステップS33;Yes)、マッピング部33は、全てのマッピングを終了したと判断し、マッピング処理を終了する。
In step S31, the
一方、科目値が空文字列でないと判定した場合(ステップS33;No)、マッピング部33は、科目値にまだデータがありながら子孫要素を取得できなかったので、マッピングエラーを文書変換の要求元へ通知する(ステップS34)。そして、マッピング部33は、マッピング処理を終了する。
On the other hand, if it is determined that the subject value is not an empty character string (step S33; No), the
一方、マッピング部33は、スタックから子孫要素の要素名を取得できたと判定した場合(ステップS32;Yes)、XBRL要素の定義体22より、取得できた子孫要素の定義である要素宣言を取得する(ステップS35)。マッピング部33は、取得した要素宣言を解析した結果、処理中の子孫要素が抽象要素か否かを判定する(ステップS36)。処理中の子孫要素が抽象要素であると判定した場合(ステップS36;Yes)、マッピング部33は、処理中の子孫要素の下位の階層にある子孫要素をスタックすべく、ステップS25に移行する。
On the other hand, when the
一方、処理中の子孫要素が抽象要素でないと判定した場合(ステップS36;No)、マッピング部33は、取得した要素宣言より、データ型222eと制約222fとnil値許可フラグ222dを取得する(ステップS37)。そして、マッピング部33は、科目値が空文字列でないか否かを判定する(ステップS38)。科目値が空文字列であると判定した場合(ステップS38;No)、マッピング部33は、処理中の子孫要素に科目値をマッピングできないので、マッピングエラーを文書変換の要求元へ通知する(ステップS39)。そして、マッピング部33は、マッピング処理を終了する。
On the other hand, if it is determined that the descendant element being processed is not an abstract element (step S36; No), the
一方、科目値が空文字列でないと判定した場合(ステップS38;Yes)、マッピング部33は、さらにマッピング処理を進めるべく、ステップS41に移行する。ステップS41では、マッピング部33は、処理中の子孫要素の要素宣言のデータ型222eが文字列型であるか否かを判定する(ステップS41)。
On the other hand, when it is determined that the subject value is not an empty character string (step S38; Yes), the
データ型222eが文字列型であると判定した場合(ステップS41;Yes)、マッピング部33は、科目値に、マッピング補助情報23に定義された任意の文字列に合致する文字列を含むか否かを判定する(ステップS42)。ここで言う任意の文字列とは、XBRL要素に応じて、科目値から抽出したい期待値の候補を意味する。これは、科目値からXBRL要素に応じた期待値を抽出するためである。例えば、科目値が「代表取締役 日本 太郎」である場合に、XBRL要素「役職」に応じて「代表取締役」、XBRL要素「氏名」に応じて「日本 太郎」を抽出する場合である。
If it is determined that the
科目値に、マッピング補助情報23に定義された任意の文字列に合致する文字列を含むと判定した場合(ステップS42;Yes)、マッピング部33は、科目値より、任意の文字列に合致する文字列を抽出する(ステップS43)。そして、マッピング部33は、さらにマッピング処理を進めるべく、ステップS51に移行する。
When it is determined that the subject value includes a character string that matches the arbitrary character string defined in the mapping auxiliary information 23 (step S42; Yes), the
一方、科目値に、マッピング補助情報23に定義された文字列を含まないと判定した場合(ステップS42;No)、マッピング部33は、さらに、次の判定処理を行う。すなわち、マッピング部33は、科目値に、マッピング補助情報23に定義された任意の区切り文字または空白文字を含むか否かを判定する(ステップS44)。これは、科目値の中で区切りとなる文字を探索するためである。
On the other hand, when it is determined that the subject value does not include the character string defined in the mapping auxiliary information 23 (step S42; No), the
科目値に、マッピング補助情報23に定義された任意の区切り文字または空白文字を含むと判定した場合(ステップS44;Yes)、マッピング部33は、区切り文字もしくは空白文字で科目値を分割し、先頭の文字列を抽出する(ステップS45)。一例として、科目値が「AAA BBB」の場合、マッピング部33は、空白文字で科目値を分割し、空白文字の前までの文字列「AAA」を抽出する。そして、マッピング部33は、さらにマッピング処理を進めるべく、ステップS51に移行する。
If it is determined that the subject value includes any delimiter or blank character defined in the mapping auxiliary information 23 (step S44; Yes), the
一方、科目値に、マッピング補助情報23に定義された区切り文字または空白文字を含まないと判定した場合(ステップS44;No)、マッピング部33は、科目値を抽出する(ステップS46)。そして、マッピング部33は、さらにマッピング処理を進めるべく、ステップS51に移行する。
On the other hand, when it is determined that the subject value does not include the delimiter or blank character defined in the mapping auxiliary information 23 (step S44; No), the
ステップS41では、データ型222eが文字列型でないと判定した場合(ステップS41;No)、マッピング部33は、科目値より、データ型に合致する文字列を抽出する(ステップS47)。そして、マッピング部33は、さらにマッピング処理を進めるべく、ステップS51に移行する。
If it is determined in step S41 that the
ステップS51では、マッピング部33は、科目値より文字列を抽出できたか否かを判定する(ステップS51)。科目値より文字列を抽出できたと判定した場合(ステップS51;Yes)、マッピング部33は、抽出した文字列を処理中の子孫要素に割り当てる(ステップS52)。そして、マッピング部33は、ステップS56に移行する。
In step S51, the
一方、科目値より文字列を抽出できなかったと判定した場合(ステップS51;No)、マッピング部33は、処理中の子孫要素がnil値を許可する要素か否かを判定する(ステップS53)。nil値を許可する要素か否かは、要素宣言より取得されたnil値許可フラグ222dを用いて判定される。
On the other hand, when it is determined that the character string cannot be extracted from the subject value (step S51; No), the
nil値を許可する要素であると判定した場合(ステップS53;Yes)、マッピング部33は、処理中の子孫要素に何も割り当てず、nil属性に「true」を設定する(ステップS54)。そして、マッピング部33は、スタックされた次の子孫要素を処理すべく、ステップS31に移行する。
If it is determined that the element is an element that allows the nil value (step S53; Yes), the
一方、nil値を許可する要素でないと判定した場合(ステップS53;No)、マッピング部33は、科目値よりデータを抽出できなかったので、マッピングエラーを文書変換の要求元へ通知する(ステップS55)。そして、マッピング部33は、マッピング処理を終了する。
On the other hand, if it is determined that the element is not an element that permits the nil value (step S53; No), the
ステップS56では、マッピング部33は、科目値について、抽出した文字列の前に文字列が存在するか否かを判定する(ステップS56)。抽出した文字列の前に文字列が存在すると判定した場合(ステップS56;Yes)、マッピング部33は、科目値について、抽出した文字列の前の文字列を削除する(ステップS57)。一例として、科目値が「第100期 (自 平成22年・・・」であり、抽出した文字列が「100」である場合について説明する。科目値について、抽出した文字列の前の文字列は「第」である。すると、マッピング部33によって、科目値は、「第」と抽出した文字列「100」を除外した「期 (自 平成22年・・・」となる。そして、マッピング部33は、ステップS58に移行する。
In step S56, the
一方、抽出した文字列の前に文字列が存在しないと判定した場合(ステップS56;No)、マッピング部33は、ステップS58に移行する。ステップS58では、マッピング部33は、科目値を更新する(ステップS58)。すなわち、次に処理される子孫要素に用いられる科目値は、抽出した文字列の前の文字列があった場合、抽出した文字列と抽出した文字列の前の文字列を除外した内容に更新される。また、次に処理される子孫要素に用いられる科目値は、抽出した文字列の前の文字列がなかった場合、抽出した文字列を除外した内容に更新される。そして、マッピング部33は、スタックされた次の子孫要素を処理すべく、ステップS31に移行する。
On the other hand, if it is determined that there is no character string before the extracted character string (step S56; No), the
[実施例の効果]
上記実施例によれば、文書変換装置1は、XBRL文書41の要素間の階層関係を含む表示ツリー221に基づいて、財務報告書21に含まれる科目のうちXBRL文書41において子孫を有する要素に対応する科目を検出する。そして、文書変換装置1は、検出した科目の値を分割する。そして、文書変換装置1は、分割された値を、検出した科目に対応するXBRL文書41における要素の子要素にマッピングする。さらに、文書変換装置1は、マッピングされた値と子要素とを用いて、財務報告書21をXBRL文書41に変換する。かかる構成によれば、文書変換装置1は、財務報告書21からXBRL文書41を作成する際、財務報告書21の科目を表示ツリー221の要素に適切にマッピングすることができる。[Effect of Example]
According to the above-described embodiment, the
また、上記実施例によれば、文書変換装置1は、科目の科目値を、表示ツリー221に含まれる要素の子孫関係となる要素のデータ型に応じて分割する。かかる構成によれば、文書変換装置1は、例えば要素のデータ型が日付型であったり整数型であったりする場合、要素のデータ型に合った文字列を科目値から抽出することが可能となる。この結果、文書変換装置1は、財務報告書21の科目の科目値を表示ツリー221の要素に適切にマッピングすることができる。
Further, according to the above embodiment, the
また、上記実施例によれば、文書変換装置1は、科目の科目値に、要素に対応付ける内容として不要な文字列がある場合には、科目の科目値から不要な文字列を削除する。かかる構成によれば、文書変換装置1は、要素へマッピングする内容の精度を高めることができる。
Further, according to the above embodiment, the
また、上記実施例によれば、文書変換装置1は、表示ツリー221に含まれる要素の子孫関係となる要素のデータ型が文字列型である場合、科目の科目値に予め定義された任意の文字列と一致する文字列が含まれていれば、科目値から一致する文字列を抽出する。そして、文書変換装置1は、抽出した文字列を分割された内容とする。かかる構成によれば、文書変換装置1は、要素のデータ型が文字列型である場合に、科目値から期待する文字列を抽出することができる。すなわち、文書変換装置1は、要素へマッピングする内容の精度をさらに高めることができる。
Further, according to the above-described embodiment, the
また、上記実施例によれば、文書変換装置1は、科目の科目値に予め定義された任意の文字列と一致する文字列が含まれていなければ、科目の科目値に区切り文字または空白文字がある場合には、以下の処理を行う。すなわち、文書変換装置1は、科目の科目値の先頭から区切り文字または空白文字の前までの文字列を分割された内容とする。かかる構成によれば、文書変換装置1は、要素のデータ型が文字列型である場合であって、区切り文字または空白文字を用いて文字列を分割できるので、科目値を子孫関係の要素に適切にマッピングをすることが可能となる。
Further, according to the above embodiment, the
[プログラム等]
なお、実施例によれば、文書変換装置1は、財務報告書21に関し、財務報告書21に含まれる科目の値を、XBRL要素にマッピングする場合について説明した。しかしながら、文書変換装置1は、財務報告書21のみならず財務会計報告全般に関する報告書であってテキスト文書の報告書に含まれる科目の値を、XBRL要素にマッピングする場合であっても良い。これにより、文書変換装置1は、テキスト文書(ワープロ文書を含む)からXBRL文書への変換を汎用的に行うことができる。[Programs]
In addition, according to the Example, the
また、文書変換装置1は、既知のパーソナルコンピュータ、ワークステーション等の情報処理装置に、上記した制御部3と、記憶部2等の各機能を搭載することによって実現することができる。
Further, the
また、図示した文書変換装置1の各構成要素は、必ずしも物理的に図示の如く構成されていることを要しない。すなわち、文書変換装置1の分散・統合の具体的態様は図示のものに限られず、その全部または一部を、各種の負荷や使用状況等に応じて、任意の単位で機能的または物理的に分散・統合して構成することができる。例えば、レイアウト解析部31と定義体解析部32とを1個の部として統合しても良い。一方、マッピング部33を、財務報告書21の中で科目値を分割する科目を検出する検出部と、検出した科目の科目値を分割し、分割した科目値の各値を各XBRL要素にマッピングするマッピング部とに分散しても良い。また、財務報告書21やXBRL要素の定義体22等の記憶部2を文書変換装置1の外部装置としてネットワーク経由で接続するようにしても良い。
Further, each component of the illustrated
また、上記実施例で説明した各種の処理は、あらかじめ用意されたプログラムをパーソナルコンピュータやワークステーション等のコンピュータで実行することによって実現することができる。そこで、以下では、図1に示した文書変換装置1と同様の機能を実現する文書変換プログラムを実行するコンピュータの一例を説明する。図11は、文書変換プログラムを実行するコンピュータの一例を示す図である。
The various processes described in the above embodiments can be realized by executing a program prepared in advance on a computer such as a personal computer or a workstation. In the following, an example of a computer that executes a document conversion program that realizes the same function as the
図11に示すように、コンピュータ200は、各種演算処理を実行するCPU203と、ユーザからのデータの入力を受け付ける入力装置215と、表示装置209を制御する表示制御部207を有する。また、コンピュータ200は、記憶媒体からプログラム等を読取るドライブ装置213と、ネットワークを介して他のコンピュータとの間でデータの授受を行う通信制御部217とを有する。また、コンピュータ200は、各種情報を一時記憶するメモリ201と、HDD205を有する。そして、メモリ201、CPU203、HDD205、表示制御部207、ドライブ装置213、入力装置215、通信制御部217は、バス219で接続されている。
As illustrated in FIG. 11, the
ドライブ装置213は、例えばリムーバブルディスク211用の装置である。HDD205は、文書変換プログラム205aおよび文書変換関連情報205bを記憶する。
The
CPU203は、文書変換プログラム205aを読み出して、メモリ201に展開する。文書変換プログラム205aは、文書変換プロセス201aとして機能する。
The
例えば、文書変換プロセス201aは、制御部3の各機能部に対応する。文書変換関連情報205bは、財務報告書21、XBRL要素の定義体22およびマッピング補助情報23に対応する。
For example, the
なお、文書変換プログラム205aについては、必ずしも最初からHDD205に記憶させておかなくても良い。例えば、コンピュータ200に挿入されるフレキシブルディスク(FD)、CD−ROM、DVDディスク、光磁気ディスク、ICカード等の「可搬用の物理媒体」に当該プログラムを記憶させておく。そして、コンピュータ200がこれらから文書変換プログラム205aを読み出して実行するようにしても良い。
Note that the
1 文書変換装置
2 記憶部
3 制御部
21 財務報告書
22 XBRL要素の定義体
221 表示ツリー
222 要素宣言
23 マッピング補助情報
31 レイアウト解析部
32 定義体解析部
33 マッピング部
34 出力部
41 XBRL文書DESCRIPTION OF
Claims (7)
前記第2の文書の項目間の階層関係を含む階層化文書に基づいて、前記第1の文書に含まれる項目のうち前記第2の文書において子を有する項目に対応する項目を検出し、前記検出した項目である検出項目の内容を分割し、
前記分割された内容を、前記検出項目に対応する前記第2の文書における項目の子項目に対応付け、
前記対応付けられた内容と前記子項目とを用いて、前記第1の文書を前記第2の文書に変換する
処理をコンピュータに実行させることを特徴とするプログラム。In a program for converting from a first document to a second document,
Detecting an item corresponding to an item having a child in the second document among items included in the first document based on a hierarchical document including a hierarchical relationship between items of the second document; Divide the content of the detected item that is the detected item,
Associating the divided contents with child items of items in the second document corresponding to the detection items;
A program that causes a computer to execute a process of converting the first document into the second document using the associated contents and the child items.
処理をコンピュータに実行させることを特徴とする請求項1に記載のプログラム。The division process causes the computer to execute a process of dividing the content of the detection item according to a data type of a child item of the item in the second document corresponding to the detection item. The program according to 1.
処理をコンピュータに実行させることを特徴とする請求項1または請求項2に記載のプログラム。In the case where the content of the detection item includes an unnecessary character string as the content to be associated with the child item, the dividing process causes the computer to execute a process of deleting the unnecessary character string from the content of the detection item. The program according to claim 1 or 2, wherein the program is characterized by the following.
処理をコンピュータに実行させることを特徴とする請求項2に記載のプログラム。When the data type of the child item of the item in the second document corresponding to the detection item is a character string type, the dividing process is associated with the child item defined in advance in the content of the detection item. If a character string that matches a specific character string is included, a character string that matches is extracted from the content of the detection item, and the computer is caused to execute a process of making the extracted character string into divided content The program according to claim 2.
処理をコンピュータに実行させることを特徴とする請求項4に記載のプログラム。If the content of the detection item does not include a predefined character string that matches a specific character string associated with the child item, the process of dividing the content of the detection item is a delimiter or a blank character. 5. The program according to claim 4, wherein if there is, the computer is caused to execute a process of dividing the character string from the beginning of the content of the detection item to before the delimiter or the blank character. .
前記第2の文書の項目間の階層関係を含む階層化文書に基づいて、前記第1の文書に含まれる項目のうち前記第2の文書において子を有する項目に対応する項目を検出し、前記検出した項目である検出項目の内容を分割する分割部と、
前記分割部によって分割された内容を、前記検出項目に対応する前記第2の文書における項目の子項目に対応付ける対応付け部と、
前記対応付け部によって対応付けられた内容と前記子項目とを用いて、前記第1の文書を前記第2の文書に変換する変換部と
を有することを特徴とする文書変換装置。In a document conversion apparatus for converting a first document into a second document,
Detecting an item corresponding to an item having a child in the second document among items included in the first document based on a hierarchical document including a hierarchical relationship between items of the second document; A dividing unit that divides the content of the detected item that is the detected item;
An associating unit that associates the content divided by the dividing unit with a child item of an item in the second document corresponding to the detection item;
A document conversion apparatus comprising: a conversion unit that converts the first document into the second document using the contents associated with the association unit and the child items.
前記第2の文書の項目間の階層関係を含む階層化文書に基づいて、前記第1の文書に含まれる項目のうち前記第2の文書において子を有する項目に対応する項目を検出し、前記検出した項目である検出項目の内容を分割し、
前記分割された内容を、前記検出項目に対応する前記第2の文書における項目の子項目に対応付け、
前記対応付けられた内容と前記子項目とを用いて、前記第1の文書を前記第2の文書に変換する
各処理を実行することを特徴とする文書変換方法。A computer for converting from a first document to a second document;
Detecting an item corresponding to an item having a child in the second document among items included in the first document based on a hierarchical document including a hierarchical relationship between items of the second document; Divide the content of the detected item that is the detected item,
Associating the divided contents with child items of items in the second document corresponding to the detection items;
A document conversion method comprising: executing each process of converting the first document into the second document using the associated contents and the child items.
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2012/067870 WO2014010068A1 (en) | 2012-07-12 | 2012-07-12 | Program, document conversion device, and document coversion method |
Publications (2)
Publication Number | Publication Date |
---|---|
JPWO2014010068A1 true JPWO2014010068A1 (en) | 2016-06-20 |
JP5991376B2 JP5991376B2 (en) | 2016-09-14 |
Family
ID=49915570
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014524560A Active JP5991376B2 (en) | 2012-07-12 | 2012-07-12 | Program, document conversion apparatus, and document conversion method |
Country Status (5)
Country | Link |
---|---|
US (1) | US10127208B2 (en) |
EP (1) | EP2874070A4 (en) |
JP (1) | JP5991376B2 (en) |
AU (1) | AU2012385075B2 (en) |
WO (1) | WO2014010068A1 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104731941B (en) * | 2015-03-31 | 2018-02-23 | 浪潮集团有限公司 | A kind of method based on XBRL technologies from unstructured financial report crawl data |
EP3460677A4 (en) | 2016-05-16 | 2019-12-11 | Fujitsu Limited | Assessment program, assessment device, and assessment method |
JP7354399B1 (en) | 2022-12-22 | 2023-10-02 | 株式会社プロネクサス | Document data generation device, control method for document data generation device, and document data generation program |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH1011441A (en) * | 1996-06-26 | 1998-01-16 | Fuji Xerox Co Ltd | Device and method for converting document structure |
JPH1021249A (en) * | 1996-06-28 | 1998-01-23 | Hitachi Ltd | Method for generating key word extraction rule |
JP2001290801A (en) * | 2000-02-04 | 2001-10-19 | Fujitsu Ltd | Structured document system, structured documentation program, and computer-readable storage medium |
Family Cites Families (13)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7100112B1 (en) * | 1999-05-20 | 2006-08-29 | Microsoft Corporation | Dynamic properties of documents and the use of these properties |
US20010014899A1 (en) * | 2000-02-04 | 2001-08-16 | Yasuyuki Fujikawa | Structural documentation system |
JP4091726B2 (en) * | 2000-02-23 | 2008-05-28 | インターナショナル・ビジネス・マシーンズ・コーポレーション | Method for generating display rule of structured document, medium on which system and program are recorded, method for changing structured document and its document type definition, medium on which system and program are recorded |
US6968500B2 (en) * | 2000-04-05 | 2005-11-22 | Dmitry Mikhailov | Automatic forms handling system |
US20040205562A1 (en) * | 2001-12-27 | 2004-10-14 | G.E. Information Services, Inc. | System and method for transforming documents to and from an XML format |
JP3888621B2 (en) * | 2002-02-21 | 2007-03-07 | インターナショナル・ビジネス・マシーンズ・コーポレーション | Document processing system, document processing method and program |
JP2003316765A (en) | 2002-04-23 | 2003-11-07 | Hitachi Ltd | Hierarchized document mapping device |
US7539940B2 (en) * | 2002-10-09 | 2009-05-26 | Microsoft Corporation | System and method for converting between text formatting or markup language formatting and outline structure |
US7296028B1 (en) * | 2004-04-30 | 2007-11-13 | Sap Ag | System and method for mapping object-oriented program code to a database layer |
JP2006011549A (en) | 2004-06-22 | 2006-01-12 | Mitsubishi Electric Corp | Structured document conversion device and program |
US7676741B2 (en) * | 2006-01-31 | 2010-03-09 | Microsoft Corporation | Structural context for fixed layout markup documents |
JP2007299064A (en) | 2006-04-27 | 2007-11-15 | Masanori Fukushima | Medical information management support device |
US8032822B1 (en) * | 2006-07-28 | 2011-10-04 | Intuit Inc. | Method and system for explaining dependencies on a document |
-
2012
- 2012-07-12 AU AU2012385075A patent/AU2012385075B2/en active Active
- 2012-07-12 WO PCT/JP2012/067870 patent/WO2014010068A1/en active Application Filing
- 2012-07-12 JP JP2014524560A patent/JP5991376B2/en active Active
- 2012-07-12 EP EP12880906.8A patent/EP2874070A4/en not_active Ceased
-
2015
- 2015-01-06 US US14/590,275 patent/US10127208B2/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH1011441A (en) * | 1996-06-26 | 1998-01-16 | Fuji Xerox Co Ltd | Device and method for converting document structure |
JPH1021249A (en) * | 1996-06-28 | 1998-01-23 | Hitachi Ltd | Method for generating key word extraction rule |
JP2001290801A (en) * | 2000-02-04 | 2001-10-19 | Fujitsu Ltd | Structured document system, structured documentation program, and computer-readable storage medium |
Also Published As
Publication number | Publication date |
---|---|
EP2874070A4 (en) | 2015-12-23 |
US20150120769A1 (en) | 2015-04-30 |
EP2874070A1 (en) | 2015-05-20 |
JP5991376B2 (en) | 2016-09-14 |
AU2012385075A1 (en) | 2015-01-29 |
US10127208B2 (en) | 2018-11-13 |
AU2012385075B2 (en) | 2016-07-21 |
WO2014010068A1 (en) | 2014-01-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10366123B1 (en) | Template-free extraction of data from documents | |
US9075833B2 (en) | Generating XML schema from JSON data | |
KR101298415B1 (en) | Annotating documents in a collaborative application with data in disparate information systems | |
JP4189416B2 (en) | Structured document management system and program | |
US9213893B2 (en) | Extracting data from semi-structured electronic documents | |
WO2019085474A1 (en) | Calculation engine implementing method, electronic device, and storage medium | |
AU2021315432B2 (en) | Generating machine renderable representations of forms using machine learning | |
JP5991376B2 (en) | Program, document conversion apparatus, and document conversion method | |
US9613067B2 (en) | Defining and transforming entity relationship-XML hybrid data models | |
US20220156245A1 (en) | System and method for managing custom fields | |
JP2009093389A (en) | Information processor, information processing method, and program | |
KR101062655B1 (en) | Metadata Management System Using Tag and Its Method | |
US9946698B2 (en) | Inserting text and graphics using hand markup | |
US20160171018A1 (en) | Append structured data system for maintaining structured format compatibility | |
JP4904828B2 (en) | Information analysis knowledge management device, data structure, information analysis device, dictionary generation method and program | |
Klımek et al. | Reverse-engineering of XML schemas: a survey | |
US11816154B2 (en) | Methods and systems for generating a unified metadata model | |
US11875105B2 (en) | System and method integrating machine learning algorithms to enrich documents in a content management system | |
Choi et al. | A study on efficiency of markup language using DOM tree | |
US20220245154A1 (en) | Techniques for managing data in a data processing system using data entities and inheritance | |
JP5156491B2 (en) | Information processing apparatus, information processing method, and program | |
JP6102444B2 (en) | Design document management program, design document management method, and information processing apparatus | |
JP5696280B1 (en) | Term unification system, term unification program, and term unification method | |
CN117421365A (en) | Data conversion method, device, computer equipment and storage medium | |
JP2019040261A (en) | Information processing apparatus and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
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: 20160719 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20160801 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5991376 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |