Creating Metadata- Research and Development Experiences 1. Reconstruction of Catalogue Data
2. Reconstruction of Classical Text
3. Creation of Historical Earthquakes Database
4. MANGA Database
5. Recent Study

Shoichiro HARA
Center for Integrated Area Studies, Kyoto University
2012-12-14
International Symposium on Knowledge Communities 2012@Tsukuba University

1. Reconstruction of Catalogue Data
 Migration of catalogue data from old system to new system Reconstruction of portable/durable metadata Problems and solutions
 Record specification was not complete
 Need to check bye by byte
 Reconstruction of the specification
 Redefinition of schema by SGML DTD
 Non-portable data
• Integer, character, string etc.
 Reconstruct SGML readable data Different JIS standard
 Convert original KEIS code (Character Set: JIS C 6226-1978, Encode:

EUC) to JIS X0208-1990 and JIS X 0212-1990
 Extra-standard characters SGML entities

Non-Portable Data
Dumped Text Data example
壮崛頽髟・韵@@@@@@@@陦毅苅毅韮欧蠅罎Δ気鵑擦曚Δ△い擦鵑海曚@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@鶯鴪鴟鴪鴪・・@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@・・・・・・・@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@隆三世法・
愛染五法@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@００
１９９９９９９９９頌鶯%齔A齣P齟X齧j・q００＄ａ０オ０８１５４００１＄ｂ０＄ｃ０
Ｏ％００＄ａ０隆三世法・愛染五法（リュウサンゼホウアイゼンゴホウ）＄ｎ０００％０
０＄ａ０写＄ｂ０１＄ｃ０軸％００＄ａ０１７％００＄ａ０Ｎ１＄ａ０Ｎ２＄ａ０Ｐ３％

Binary

C1 D4

D6

C1

01 B4

KEIS

A M

O

A

DirBase Tags StartPos Data (Call Number)

00 07 01 D0 85 F0 F8 F1 F5 F4・・・

Microfilm No Corr. New Rec. =436

=7

(KEIS: Kanji processing Extended Information System: Hitachi)=464

Byte by Byte Check

Reconstructed StructureDTD<!-******************************************************************************** 国文学研究資料館基礎ファイルＤＴＤ* （マイクロフィルムレコード, 和古書レコード兼用）** 履歴* 第１版: 1997年01月28日(火)* 第２版: 1997年04月14日(月)* ・<著者>タグの属性に「他(ON | OFF) "OFF"」を追加した。
* 第３版: 1997年08月25日(月)* ・原資料請求番号タグ, マイクロフィルム請求番号タグ配下に新しく、* 第５レベルを追加した。
* 第４版: 1997年09月08日(月)* ・注記タグに属性"注記型"を追加した。
******************************************************************************--><!DOCTYPE 目録[<!ELEMENT 目録- O (レコード+) ><!ELEMENT レコード- O (標目部, 記述部) ><!ELEMENT 標目部- O (統一書名, 著者名?) ><!ELEMENT 記述部- O (請求情報, 記載題?, 注記?, 刊記?, 書写記?, 対象事項?, フィルム種別?,
サービス区分?, 寄託者?, 所蔵者?, 参照?, 旧帳票?) ><!ELEMENT 統一書名- O (書名, 同名異書番号) ><!ELEMENT 書名- O (表記, よみ) ><!ELEMENT 著者名- O (著者*) ><!ELEMENT 請求情報- O (原資料請求番号, マイクロフィルム請求番号?, 紙焼写真本請求番号?,
資料キー?)><!ELEMENT 原資料請求番号- O (第１レベル, 第２レベル, 第３レベル?, 第４レベル?, 第５レベル?) ><!ELEMENT マイクロフィルム請求番号- O (第１レベル, 第２レベル, 第３レベル?, 第４レベル?, 第５レベル?) ><!ELEMENT 資料キー- O (キー, 合綴叢書番号?)><!ELEMENT 第１レベル- O (#PCDATA) ><!ELEMENT 第２レベル- O (#PCDATA) ><!ELEMENT 第３レベル- O (#PCDATA) ><!ELEMENT 第４レベル- O (#PCDATA) ><!ELEMENT 第５レベル- O (#PCDATA) ><!ELEMENT 紙焼写真本請求番号- O (#PCDATA) ><!ELEMENT キー- O (#PCDATA) ><!ELEMENT 合綴叢書番号- O (#PCDATA) ><!ELEMENT 記載題- O (内題*, 目録題*, 扉題*, 扉裏題*, 尾題*, 見返し題*, 裏見返し題*, 外題*, 序首題*,
跋首題*, 刊記題*, 柱題*, 奥中題*, 序中題*, 跋中題*, 帙外題*, 合題*) ><!ELEMENT (内題| 目録題| 扉題| 扉裏題| 尾題| 見返し題| 裏見返し題| 外題| 序首題| 跋首題| 刊記題|
柱題| 奥中題| 序中題| 跋中題| 帙外題| 合題)- O (表記, よみ) ><!ELEMENT 注記- O (叢書注記*, 合綴注記*, 叢書端本注記*, 欠本注記*, 残本注記*, 著者注記*, 一般注記*,
装丁注記*, 印記*) ><!ELEMENT 叢書注記- O ((叢書名, 同名異書番号)+) ><!ELEMENT 合綴注記- O ((合綴名, 同名異書番号)+) ><!ELEMENT 叢書名- O ( #PCDATA | (表記,よみ) ) ><!ELEMENT 合綴名- O (表記, よみ) ><!ELEMENT 刊記- O ( (著者, 地名)*, (書肆, 地名)*, (蔵版者, 地名)*, (彫師, 地名)*, (浄書者, 地
名)*,(装幀者, 地名)*,(校合者, 地名)*, (画家, 地名)*, (編者, 地名)*, (校訂者, 地
名)*,(述者, 地名)*, (評者, 地名)*, (撰者, 地名)*, (補者, 地名)*, (筆写者, 地
名)*,(訳者, 地名)*, (不明, 地名)*, 刊年?, 記述刊年?, 西暦刊年?) ><!ELEMENT (著者| 書肆| 蔵版者| 彫師| 浄書者| 装幀者| 校合者| 画家| 編者| 校訂者| 述者| 評者| 撰者|
補者| 筆写者| 訳者| 地名)- O (表記, よみ) ><!ELEMENT 不明- O (#PCDATA) ><!ELEMENT 不明- O (#PCDATA) ><!ELEMENT 刊年- O (#PCDATA) ><!ELEMENT 記述刊年- O (#PCDATA) ><!ELEMENT 西暦刊年- O (#PCDATA) ><!ELEMENT 書写記- O (書写者名*, 書写年*, 記述書写年*, 西暦書写年*) ><!ELEMENT 書写者名- O (表記, よみ) ><!ELEMENT 書写年- O (#PCDATA) ><!ELEMENT 記述書写年- O (#PCDATA) ><!ELEMENT 西暦書写年- O (#PCDATA) ><!ELEMENT 対象事項- O (原本事項?, フィルム事項?) ><!ELEMENT 原本事項- O (刊写別, 員数, 単位, 大きさ?, 規格?) ><!ELEMENT フィルム事項- O (コマ数, リール数?) ><!ELEMENT 刊写別- O (#PCDATA) ><!ELEMENT 員数- O (#PCDATA) ><!ELEMENT 単位- O (#PCDATA) ><!ELEMENT 大きさ- O (#PCDATA) ><!ELEMENT 規格- O (#PCDATA) ><!ELEMENT コマ数- O (#PCDATA) ><!ELEMENT リール数- O (#PCDATA) ><!ELEMENT フィルム種別- O (フィルム*, 紙焼?) ><!ELEMENT フィルム- O (#PCDATA) ><!ELEMENT 紙焼- O (#PCDATA) ><!ELEMENT 叢書端本注記- O (叢書名, 記述*) ><!ELEMENT (欠本注記| 残本注記| 著者注記| 一般注記| 装丁注記| 印記)- O (記述+) ><!ELEMENT サービス区分- O (#PCDATA) ><!ELEMENT 寄託者- O (#PCDATA) ><!ELEMENT 所蔵者- O (所蔵者コード, 函架番号?, 所蔵者名?) ><!ELEMENT (所蔵者コード| 函架番号| 所蔵者名)- O (#PCDATA) ><!ELEMENT 参照- O ( (参照書名, 同名異書番号)+ ) ><!ELEMENT 参照書名- O (表記, よみ) ><!ELEMENT 旧帳票- O (１０１*,１０２*,１０３*,１６１*,２０９*,２６１*,２６２*,２６３*,２６４*,２７１*) ><!ELEMENT (１０１ | １０２ | １０３ | １６１ | ２０９ | ２６１ | ２６２ | ２６３ | ２６４ | ２７１)
- O (#PCDATA)><!-- 共通エレメント--><!ELEMENT 同名異書番号- O (#PCDATA) ><!ELEMENT 表記- O ( 冠称等*, 記述+ ) ><!ELEMENT よみ- O ( 冠称等*, 記述+ ) ><!ELEMENT 記述- O ( ( #PCDATA | 訂正)+ ) ><!ELEMENT 冠称等- O (#PCDATA) ><!ELEMENT 訂正- O (#PCDATA) ><!-- 属性--><!ATTLIST レコードType (和古書| マイクロフィルム) #REQUIREDImage (Yes | No) "No"Level NMTOKEN "A"DTD.pdf
Service NMTOKEN "A"
Status NMTOKEN "O"
Published NUMBER "0000" ><!ATTLIST 著者役割(著,画,編,撰,詠,点,判,述,註,訂,序,跋,評,訳,講,記,書,補,伝,説,聞,吟,詞) #IMPLIED
他(ON | OFF) "OFF"sf NUMBER "0" ><!ATTLIST (第１レベル| 第２レベル| 第３レベル| 第４レベル| 第５レベル| キー| 合綴叢書番号)
sf NUMBER "0" ><!ATTLIST (内題| 目録題| 扉題| 扉裏題| 尾題| 見返し題| 裏見返し題| 外題| 序首題| 跋首題| 刊記題|
柱題| 奥中題| 序中題| 跋中題| 帙外題)
sf NUMBER "0" ><!ATTLIST 合題レベル(1,2) #REQUIREDf NUMBER "0" >・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・

Data Conversion

Kanji （漢字） Problems
 Transcription of classical materials needs more than 50,000

ideographic characters （漢字） Standard characters are about 10,000
 Then need extra-standard characters （外字） KEIS extra-standard characters (0Xnnnn) ⇒ SGML entities (&Knnnn)

 Standard characters have been changed• JIS C 6226-1978• JIS X0208-1983• JIS X0208-1990• JIS X 0212-1990 etc.
 If computers and print devices use different standard, wrong characters are

printed out Some characters are added and removed
 Some characters are changed their codes

Kanji Conversion Procedure
Following pair characters in JIS C
6226-1978 were interchanged theircodes in JIS X 0208-1983(KUTEN) (KUTEN)
1619
8256
1809
8284
1934
7358
1941
5788
1986
6762
2035
6285
2050
7561
2359
8084
2560
6672
2841
7302
3157
8055
3308
7645
3659
5268
3755
6674
3778
5977
3783
6225
3886
7778
3972
7404
4116
5956
4389
4854
4489
7314
4722
6838

Following characters in JIS C 6226-1978 were removed
in JIS X 0208-1983, but were revival in JIS X 02121990. These characters were mapped to Extra code.
C 6226-1978 X 0212-1990
2202
1734
1602
2164
1990
2258
3925
2276
3722
2420
2840
2690
3363
3243
3647
3259
5825
3334
4014
4053
3834
4112
1775
4179
3373
4587
3788
4880
2911
5225
2350
5258
4573
5639
3053
5722
4725
5988
2277
6452
3063
6683
4016
6687
4343
7204
3731
7219
1810
7631
2420
7659
2577
7679
4445
7680

External Code&Kb1c2;&Kb5e0;&Kb6da;&Kb6ec;&Kb8b4;&Kbafa;&Kc0cb;&Kc0db;&Kc1c2;&Kc8d5;&Kc9ac;&Kc9ef;&Kcdf7;&Kd0f0;&Kd4d7;&Kd4da;&Kd8c7;&Kd9b6;&Kdbf8;&Ke0d4;&Ke2f3;&Ke2f7;&Ke8a4;&Ke8b3;&Kecbf;&Kecdb;&Kecef;&Kecf0;Reconstructed Catalogue Sample<目録>・・・・・・・・・・・・・・・・・・・<レコード Type="和古書" Image="No" Level="A" Service="A" Status="O" Published="0000"><標目部><統一書名><書名 sf="0"><表記><記述>&Kf4e4;&Kb6ec;鈔</記述></表記><よみ><記述>アイノウショウ</記述></よみ></書名><同名異書番号 sf="0">００</同名異書番号></統一書名><著者名><著者 役割="著" 他="OFF" sf="0"><表記><記述>行誉</記述></表記><よみ><記述>ギョウヨ</記述></よみ></著者></著者名></標目部><記述部><請求情報><原資料請求番号><第１レベル sf="0">Ｗマ３</第１レベル><第２レベル sf="0">３３</第２レベル><第３レベル sf="0">１～１５</第３レベル></原資料請求番号><資料キー><キー sf="0">００００００６４０</キー><合綴叢書番号 sf="0"></合綴叢書番号></資料キー></請求情報><記載題> ・・・・・・・・・・・・・・・・・・・

DTP for Catalogue Data
Convert SGML data into LaTex
 Printing by LaTex tools2. Reconstruction of Classical Text
 「日本古典文学大系」本文データベース：The Full-Text

Database for “The Anthology of Japanese Classical Literature”



100 Volumes, About 560 Titles (Approx. 30,000,000 characters) Problems and solutions
 Specific data structure Tried to introduce TEI
 Ambiguous data definition (KOKIN Rule) Lexical and syntax check Redefinition of schema by SGML/XML DTD
 Data conversion by program (XSLT was not available at this time) No tools to manipulate text data Converted to SGML/XML Difficult to use on the Web
 SGML/XML → HTML

 Extra-standard characters Unicode SGML/XML Links

Encoding Schema “KOKIN Rules”
 KOKIN Rules

Original Image KOKubungaku INformation Rules
 Reconstruction of Original Text

 Objective
 KOKIN Rule 1: Data Structure Definition
 KOKIN Rule2: Description of Japanese Texts
 KOKIN Rule 3: Private Purposes Design
 Clarity and ease of use by researchers

Transcription by
KOKIN Rules

KOKIN Rule 1(Logical Structure of Text)<Logical Record>::= <Tag Begin><Tag><Tag End>|<Tag Begin><Tag><Data><Tag End>
<Tag Begin> ::= ‘￥(Japanese-Yen-Mark)'<Tag End>::= ‘★(Star-Mark)'<Tag>::= <Tag Symbol>|<Tag Symbol><Tag Attribute><Data>::= <Line>|<Original Data>|<Repeating Symbol><Original Data><Line>::= <Original Data>|<Serial Number><Original Data><Serial Number>::= see Table<Repeating Symbol> ::= ';'<Original Data>::= see flag Rule
<Tag Symbol>::= see Table /* Pre-Defined Tags */<Tag Attribute>::= see Table

KOKIN Rule 2(Japanese Text Description)<Original Data>::= <Flag Begin><Data Element><Flag End><Supp>| <DataElement><SpaceFlag> <Supp><Data Element>|<Data Element><Data Element> ::= <String><Flag Begin>|<Flag End> <Space Flag>::= '/'<Supp>::= <Right Supp>|<Left Supp>|<Bi-Supp><Right Supp>::= <Supp Begin><Supp Element><Supp End>
<Left Supp>::= <Left Supp Begin><Supp Element><Supp End>
<Bi-Supp>::= <Supp Begin><Supp Element> '|‘ <Supp Element><Supp End>
<Supp Element> ::= <Single Supp>|<Double Supp><Single Supp>::= <Supp Element><Double Supp>::= <Supp Element><Supp Separator><Supp Element><Supp Begin>::= '( '<Left Supp Begin> ::= "(|"
<Supp End>::= ')'<Supp Separator> ::= '#'<Supp Element> ::= <String>|<String><String Separator><String><String Separator>::= '='<String>::= see 3.3

Redefinition by SGML/XML DTD
・・・・・・・・・・・・・・・・・・・・・・・・・<!ELEMENT classics ( header?, text ) ><!ELEMENT header ( fileDesc, encodingDesc*, profileDesc*, revisionDesc? ) ><!ELEMENT fileDesc ( %cm.fileDesc; ) ><!ELEMENT encodingDesc ( %cm.encodingDesc; ) ><!ELEMENT profileDesc ( %cm.profileDesc; ) ><!ELEMENT revisionDesc ( %cm.revisionDesc; ) ><!ELEMENT text ( front?, body, back? ) ><!ELEMENT front (%para1; )* ><!ELEMENT body ( body.head* | body.bibl* | (div0+ | p | %para4; )* | body.back)* ><!ELEMENT body.head ( %para1; )* ><!ELEMENT div0 ( div0.head* | div0.bibl* | (div1 | p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* | div0.back)*><!ELEMENT div1 ( div1.head* | div1.bibl* | (div2 | p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* |div1.back)* ><!ELEMENT div2 (div2.head* div2.bibl* | (div3 | p | waka-group | renga-group | table | outer-note | kobanashi-group |family-tree | %para3; )* | div2.back)* ><!ELEMENT div3 ( div3.head* | div3.bibl* | (div4 | p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* |div3.back)* ><!ELEMENT div4 ( div4.head* | div4.bibl* | (div5 | p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* |div4.back)* ><!ELEMENT div5 ( div5.head* | div5.bibl* | (div6 | p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* |div5.back)* ><!ELEMENT div6 ( div6.head* | div6.bibl* | (div7 |p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3; )* |div6.back)* ><!ELEMENT div7 ( div7.head* | div7.bibl* | ( p | waka-group | renga-group | table | outer-note | kobanashi-group | family-tree | %para3;)* | div7.back)* ><!ELEMENT back ( %para1;)* ><!ELEMENT div0.head (%para1;)* ><!ELEMENT div1.head (%para1;)* ><!ELEMENT div2.head (%para1;)* ><!ELEMENT div3.head (%para1;)* ><!ELEMENT div4.head (%para1;)* ><!ELEMENT div5.head (%para1;)* ><!ELEMENT div6.head (・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・・

Reconstruction Procedure
Digital Transcription Text (KOKIN Rules)
Scanner, Parser etc.

Reconstructed XML
XSLTFull Text
DatabaseXSLT + CSS

Web Text (HTML)XSL-FOPDF

Description ofExtra Standard Characters
KOKIN Text
天ノ／&m027888;（カトリ）ヲ以テ太子ヲ
SGML/XML Text
天ノ<ruby fg=“OFF”><rb> <gaiji set=“mojikyo” code=“027888”/></rb><rt>カトリ</rt></ruby>ヲ以テ太子ヲHTML (SGML/XML+XSLT)天ノ<ruby><rb> <img alt=“mojikyo#027888” height=“14pt”
width=“14pt” src=“http://www.mojikyo.gr.jp/gif/027/027888.gif”
name=“mojikyo_font_027888” border=“0”/> </rb><rt>カトリ</rt></ruby>ヲ以テ太子ヲMarkup Example<小作品名>醒睡笑巻之一</小作品名><噺><噺名>謂被謂物之由来</噺名><小噺><小噺番号 num= "１ "><本文レコード><行番号 pos="M" num= "５ ">△そらことをいふ物を、などうそつきとハいひならハせ<行番号 pos="M" num= "６ ">し。されはにや、うそといふ鳥、木のそらにとまりゐて<傍記素 fg="OFF">琴</傍記素><傍記>こと</傍記><行番号 pos="M" num= "７ ">をひく<傍記素 fg="OFF">縁</傍記素><傍記>ゑん</傍記>によせ、そらことをうそつきといふよし。
</本文レコード></小噺>

醒睡笑巻之一
謂被謂物之由来Line

そらことをいふ物を､などうそつきとﾊいひならﾊせことし｡されはにや､うそといふ鳥､木のそらにとまりゐて琴ゑん

をひく縁によせ､そらことをうそつきといふよし｡

Simple Annotation

Annotation

Markup Example (cont.)<行番号 pos="L" num= "９ "><傍記素 fg="OFF">七歩</傍記素><傍記>しつほ</傍記>とぬるゝとハ何事そ。されハ尺迦<傍記素 fg="OFF">誕生</傍記素><傍記>たんしやう</傍記>の時、阿<傍記素 fg="ON">難</傍記素><行番号 pos="L" num= "１０ "><傍記素 fg="ON">陀竜</傍記素><傍記>なん</傍記><傍記>たりう</傍記>
王ハ<傍記素 fg="OFF">湯</傍記素><傍記>ゆ</傍記>を<傍記素 fg="OFF">吐</傍記素><傍記>はき</傍記>、<傍記素 fg="OFF">難陀竜</傍記素><傍記>なんたりう</傍記>王ハ水を吐、此うぶ湯にぬれなが

しっほ

たんしゃう

なん

七歩とぬるゝとハ何事そ。されハ尺迦誕生の時、阿難
たりう

ゆ

なんたりう

陀竜王ハ湯を吐、難陀竜王ハ水を吐、此うぶ湯にぬれながDivided Anootation

Divided Annotation

Markup Example (cont.)<行番号 pos="L" num= "６ "><傍記素 fg="OFF">窮鼠</傍記素><傍記>きうそ</傍記><傍記素 fg="OFF">還</傍記素><傍記>かへつて</傍記>嚼猫とあれは、にくむ処<傍記素 fg="OFF">狂惑</傍記素><左右傍記><右傍記>きやうあく</右傍記><左傍記>まげまとふ</左傍記></左右傍記>なる<傍記素 fg="OFF">鼠</傍記素><傍記>ねつミ</傍記><傍記素 fg="OFF">根性</傍記素><傍記>こんじやう</傍記>なるか<行番号 pos="L" num= "７ ">な。

きうそかへつて

窮鼠還
な。

きやうあく

ねつミこんじやう嚼猫とあれは、にくむ処狂惑なる鼠
まげまとふ

Double Annotation

根性なるかMarkup Example (cont.)<行番号 pos="M" num= "１１ ">△△人ならは憂名やたゝむさよふけて△△△△△<割書き fg="OFF"><行>比哥此条ニ△</行><行>心相違セリ・</行><行>ノケ申度候。</行></割書き><行番号 pos="M" num= "１２ ">△△△我手枕にかよふ梅がゝ

人ならは憂名やたゝむさよふけて
我手枕にかよふうめがゝ比哥此条ニ
心相違セリ・
ノケ申度候。

Inserted Annotation

Inserted Annotation

Reconstructed XML Text<?xml version="1.0" encoding="Shift_JIS" ?><!DOCTYPE classics SYSTEM "../../dtd/xml-n-classics2.dtd"[]><classics><text><body><div0><div0.head>方丈記</div0.head><filename id="p23" /><div1><div1.head>一</div1.head><lineno pos="L" id="l5">△ゆく河の<ruby fg="OFF"><rb>流</rb><rt>なが</rt></ruby>れは<ruby fg="OFF"><rb>絶</rb><rt>た</rt></ruby>えずして、しかも、もとの水にあらず。<ruby fg="OFF"><rb>淀</rb><rt>よど</rt></ruby>みに</lineno><lineno pos="L" id="l6"><ruby fg="OFF"><rb>浮</rb><rt>うか</rt></ruby>ぶうたかたは、かつ<ruby fg="OFF"><rb>
消</rb><rt>き</rt></ruby>えかつ<ruby fg="OFF"><rb>結</rb><rt>むす</rt></ruby>びて、<ruby fg="OFF"><rb>久
</rb><rt>ひさ</rt></ruby>しく<ruby fg="OFF"><rb>と</rb><rt>＊</rt></ruby>ゞまりたる<ruby fg="OFF"><rb>例</rb><rt>ためし</rt></ruby>なし。</lineno><lineno pos="L" id="l7"><ruby fg="OFF"><rb>世中</rb><rt>（よのなか）</rt></ruby>にある人と<ruby fg="OFF"><rb>
栖</rb><rt>（すみか）</rt></ruby>と、またかくのごとし。</lineno><lineno pos="L" id="l8">△たましきの<ruby fg="OFF"><rb>都</rb><rt>みやこ</rt></ruby>のうちに、<rubyfg="OFF"><rb>棟</rb><rt>（むね）</rt></ruby>を<ruby fg="OFF"><rb>並</rb><rt>なら</rt></ruby>べ、<rubyfg="OFF"><rb>甍</rb><rt>いらか</rt></ruby>を<ruby fg="OFF"><rb>爭</rb><rt>あらそ</rt></ruby>へる、<rubyfg="OFF"><rb>高</rb><rt>たか</rt></ruby>き、<ruby fg="OFF"><rb>い</rb><rt>＊</rt></ruby>やしき、</lineno><lineno pos=“L” id=“l9”>人の<ruby fg=“OFF”><rb>住</rb><rt>すま</rt></ruby>ひは、世々を<ruby fg=“OFF”><rb>經
</rb><rt>へ</rt></ruby>て<ruby fg=“OFF”><rb>盡</rb><rt>つ</rt></ruby>きせぬものなれど、これをまことかと尋</lineno>・・・・・・・・・・

デジタル古典本文（再掲）
Reconstructed Materials
HTML Version

PDF Version

3. Creation ofHistorical Earthquakes Database Historical analysis of earthquakes are important to know

characteristics of each earthquake
Articles about historical earthquakes are accumulated and complied as books

 Low reliability Documents were collected without precise examinations and text critiques(second and third sources, thread and thrum ...)
 Seismologists are difficult critically to read historical documents as they
didn’t take any trainings for historical materials
 Low reliability will lead to wrong seismologic conclusions as seismologists
tend to believe written issues
 Resources are huge but ...
 Only printed materials
 Difficult to access (e.g., Out of print) Difficult for researchers to retrieve information

 Necessity of high quality comprehensive text (multi- media)

database has been desired (after recompiling, proofreading
and text critiques)Purposes of the Projects(high quality comprehensive text)

1. To construct the new text database of “Historical Earthquake
Documents in the Ancient and Medieval Ages in Japan,” An interdisciplinary collaboration among seismologists, volcanologists,

historians and information scientists

2. Critically examine all the collected documents, selectappropriate ones, revise them correctly and reorganize new
documents in digital form, and3. Compose a seismic intensity database compatible with the
Intensity Data Points (IDP) prevailing in Europe.

Main Resources 大日本地震史料
 Collection of Historical Documents on Earthquakes in Japan, Edited by

Tayama (1904a, b: 2 volumes)
 増訂大日本地震史料
 Collection of Historical Documents on Earthquakes in Japan,

Enlarged and Revised Edition, Edited by Dr. Musha (1941,
1943a, b, 1951: 4 volumes)
 新収日本地震史料
 Historical Documents on Earthquakes in Japan, New Collection, Edited by Dr.

Usami and his colleagues (1981-1994: 21 volumes)
 Those are official national histories, chronicles, private

histories, diaries, biographies, essays, memoranda, letters,
memoirs, notes, etc.

Tayama

Main Resources and Comparison of the volumes

Musha

Usami et al.

Why Transcription by XML?
 Portability
 Data Independent from hardware and software

 Easy for data structure transformation
 Merge different documents
 Sort documents elements etc

 Coping with Hypermedia
 Linking with images, movies etc.
 Linking with Web application/services

Markup Guidelines※ All information needed for text critiques and revision works
must be preserved
1. Logical elements such as titles, records, sections, etc. aremarked-up
2. Editorial notes and revision notes are marked-up
3. Descriptive parts such as rubi and gaiji (external standard
characters) are marked-up
4. Layout structures such as the number of lines in a page are
NOT marked-up

Resource Examples(Historical Earthquake Document Structures)

HeaderRecordEarthquake Name
SourceGeneralDescription

Resource Examples (cont.)(Historical Earthquake Document Structures)
Note

Break
Line
Kaeri, Okuri
Etc.

Note And
Divide Line

Basic Structure of
the Classic Earthquake Documents
ClassicEarthquake
Root of the document- Volume+
A volume of historical earthquakes|- Header?
Bibliographic information of the volume|- Earthquake+
An earthquake|- Header?
Biographic information of the earthquake|- E.ID
ID of the earthquake (Must be unique)|- J.Date
Date of the earthquake by Japanese calendar|- S.Date
Date of the earthquake by European calendar|- E.Description
General description of the earthquake|- E.Sources+
Information of a material of the earthquake|- Header?
Bibliographic information of the material|- E.ID
ID of the earthquake (Must be unique)|- Source.ID
ID of the material (Must be unique)|- Source.Record+
Minimum unit on the earthquake information|- Record.ID
ID of the record (Must be unique)|- E.ID
ID of the earthquake (Must be unique)|- Source.ID
ID of the material (Must be unique)|- J.Date
Date of the event by Japanese calendar|- S.Date
Date of the event by European calendar|- Record.Description Contents of the record

Examples of XML Text<?xml version="1.0" encoding="Shift_JIS"?><?xml-stylesheet type="text/xsl" href="./ClassicEarthquake-Ext.xsl"?><!DOCTYPE ClassicEarthquake SYSTEM"./ClassicEarthquakeSimple_ver3.dtd"[]><ClassicEarthquake><Volume vol="ZOTEI"><Header><titleStmt>増訂大日本地震史料</titleStmt></Header><Earthquake page="228"><Header><titleStmt>明應七年八月二十五日（西暦 1498,9,20）</titleStmt></Header><E.ID>14980920</E.ID><J.Date>明應七年八月二十五日</J.Date><S.Date type="Gregorian">14980920</S.Date><E.Description><section>伊勢、<gaiji set=“mojikyo” code=“067322”>紀</gaiji>伊、<gaiji set=“daikanwa” code=“039047”>遠</gaiji>江、三河、駿河、甲斐、相模、伊豆
諸國、地大ニ震ヒ、瀕<gaiji set=“daikanwa” code=“017503”>海</gaiji>ノ國ハ津浪ノ害ヲ<gaiji set=“mojikyo” code=“075258”>蒙</gaiji>リ、就中伊勢國大湊ニテハ家千軒押シ流
サレ五千人<gaiji set=“daikanwa” code=“017990”>溺</gaiji>死ス、マタ鎌倉由比浜ニテハ
水勢大佛殿ニ及ビ二百人<gaiji set=“daikanwa” code=“017990”>溺</gaiji>死セリ、是日、
京都、奈良及ビ陸奥國<gaiji set=“mojikyo” code=“066797”>會</gaiji>津モ強ク震ヒ、<gaiji set="mojikyo" code="054722">餘</gaiji>動月ヲ重ネタリ、</section></E.Description>

Example of Display (MS WORD)（明応七年））
1498,8,21

六月十一日、丙子、新宮大地震、未時止ム、＊〔續本朝通鑑〕
子、諸國大地震、（明応七年六月十一日）

丙

明應七年七月二十五日（西暦京都地震フ、|未 晴)、半更地震、＊〔後法興院記〕（明応七年七月）

廿 五日 巳(明應七年八月二十五日（西暦）1498,9,20
伊勢、紀伊、遠江、三河、駿河、甲斐、相模、伊豆諸國、地大ニ震ヒ、瀕海ノ國ハ津浪ノ害ヲ蒙リ、就中伊勢國大湊ニテハ家千軒押シ流サレ五千人溺死ス、マタ鎌倉由比浜ニテハ

地

震

）

水勢大佛殿ニ及ビ二百人溺死セリ、是日、京都、奈良及ビ陸奥國會津モ強ク震ヒ、餘動月
ヲ重ネタリ、（〔御湯殿の上の日記〕（明応七年八月）

廿 五日、けさちしんけう＼／しうゆる、しょくゆへの御いのりの事、ふ行におほせいたさるゝ、
廿六日、（中略）けふもちしんちとゆる、（ 九 月 ）

二日、こよひつよくゆる、
三日、ちしんけふもちとゆる、（ 十 月 ）

一日、ちしんしたいなくゆる、
五日、ちしんゆる、例）

廿日、ちしんにつきて、ことともするよし、松ゆい御にわにて申、やかて御さたあり、め
でたし＼／（

廿四日、ちしんにつきて、いつものやしろにほつ句御さたある、きをむさうにあるよしき
こしめして、御連歌御さた、宮の御かた、ふしみ殿、そのほかあやのこうち、かんろしの中納言、はく御人す、しひつためさねしこう、はいかたの御いわゐに、いつものことく御ともねうはうたちまてまいる、めでたし、（閏十月）十八日、よなかほとにちしんこと＼／しうゆる、Databases
 Convert XML documents into HTML document
 users can access documents by general purpose browsers
 display in vertical

writing and give users
natural look and feel

 Full text database isConstructed on
PostgreSQL and PHPDatabase Example

Description from the Resource
貞観地震(Jogan Earthquake)

貞観11年5月26日(Julius: 869/7/9)

Application to GISApplication to GIS (cont.)4. MANGA Database Manga has already established itself a genre of culture– Sales in 2011: 271.7 Bill. / 1112.3 Bill.

 One of foremost Japanese pop culture– World wide market– Attractive to Japanese culture and language

 Media characteristics– Media diversity/derivation: Weekly periodicals, books, animations, movies,

dramas, theaters, parodies etc.
 Problems of Manga– Easy to be disappeared
 Easy to be out of print and/or cease publication
 Easy to be discarded
 Easy to be destroyed Importance of Metadata, digitization and preservation
 But there are no well established metadata for Manga database THEN, our trial to define new metadata of Manga

Functions of Manga Metadata
1. Ability to describe media diversity and derivation– From weekly periodicals to books and animations etc.

2. Ability to keep all aspects of Manga–

Bibliographic, texts, images, movies etc.

3. Importance of participatory data creation– No special librarians/catalogers of Manga– Need grass roots supports (expressly for foreign materials)

4. Importance of effective use of Web information– Much information about bibliographies, explanatory notes, authors,publishers etc. are available from Web– Metadata will be used to organize existing information

Thus Our Metadata should be easy to create and use should be compatible with other metadata

Components of Manga Metadata Bibliographic Metadata

DC based simple structure– Describes elementary information about general concept of work,
each work/media (such as book, novel, TV drama, movie, etc.),
each resource, etc.
–

 Structural Metadata

Describes structural component of Manga book such as Page,
Coma(Frame), Picture, Text, Symbol, etc.
– Will try to apply TEI–

 Topic Maps and Web application

Express metadata as network– Link each component with other Web data–Image Data
 Image scanning

300dpi– Gray scale（8bit）, Only cover page is color scanning– Preprocessing

Remove the cover– Then cut the binding of the book
(Bind the book again after scanning)–

43Composition of MangaExample of Structure Metadata

45

Example of Bibliographic Metadata
element

content

Title

BOYS over FLOWERS

CreatorDescription

Yoko Kamio, PSI
element
Content
Love story, http://id.ndl.go.jp/auth/ndlsh/00569390 (PSI)
print, PSI
FormatManga, book, URL

Publisher

SHUEISHA Inc., PSI

Contributor

Agent, PSI, Role

Date

1992

Type

StillImage, PSI

Subject

Identifier
SourceURL of resource

Language

Ja, PSI

Relation

isFormatOf, URL of resource

Coverage

Heisei, PSI place, PSI

RightsYoko Kamio, PSI

General View and target of Manga Metadata Three types targets

Work(著作), Expression(表現形), Manifestation(体現形) Metadata is made for each instance of the types
 Describing relationships (e.g. derivation) between instances–

Web Application for Bibliographic MetadataWeb Application for Structural Metadata
Top page

Key word search

Structural Metadata Web application
Script/Onomatopoeia list

Script/Onomatopoeia detail

Coma detail5. Recent Study(Databases for Whom ?)TargetObjectCollection
Organization
Variety
Collection Policy
Collection
Size
Metadata
Usage
Durability

Libraries, Archives
PublicPublic / General

Researches
Individual / Research Group
Research /Specific

Institutional

Individual / Research Group

Small
Consistent
Whole
Large
Standard
SimpleLong

LargeInconsistentPartialSmall
Specific / Heterogeneous
ComplexShort Challenges of CIAS
 Researchers’ database Durable , Interoperable and Flexible Repository for Heterogeneous

Datasets
 Key Technologies: XML + HTTP + JAVA + Ontology

For Flexible Database Tools
CIAS IIS is a server-side system and is less-flexible for
Researchers
1. Operation and maintenance are difficult for researchers
2. Standard metadata (difficult to manage specific metadata)
3. Flexible modification of retrieval procedures, database integration, userinterfaces and processing algorithms are difficult
4. Multi-lingual databases

Solutions: Separation of server functions and user functions*From Center-oriented to Researcher-oriented system
1. My-Database Just for a researcher or a research group• Simple data repository and basic retrieval• Simple database operation• CSV and XML files (no restriction about metadata)
2. REST(Representational State Transfer)-Like API
 User side programing environment• retrieval procedures/algorithms and/or user interfaces
3. Multi-lingual Translation ServieceMy-Database- Coping with Specific Metadata IIS

My-Database

Metadata Set②⑥Mapping
XSLT④ Converter
XSLT⑦ Standard Metadata Part

⑤ Specific Metadata Part

(Resource Sharing)(My Database)③Schema①Schema
Generic APIs
REST-like APIs
⑧GUI XSLTHTTP + HTMLHTTP + XML

Example of My-Database(Historical Earthquake Records)<?xml version="1.0" encoding="Shift_JIS"?><?xml-stylesheet type="text/xsl" href="./ClassicEarthquake-Ext.xsl"?><!DOCTYPE ClassicEarthquake SYSTEM"./ClassicEarthquakeSimple_ver3.dtd"[]><ClassicEarthquake><Volume vol="ZOTEI“><Header><titleStmt>増訂大日本地震史料</titleStmt></Header><Earthquake page="228"><Header><titleStmt>明應七年八月二十五日（西暦 1498,9,20）</titleStmt></Header><E.ID>14980920</E.ID><J.Date>明應七年八月二十五日</J.Date><S.Date type="Gregorian">14980920</S.Date><E.Description><section>伊勢、<gaiji set=“mojikyo” code=“067322”>紀</gaiji>伊、<gaiji set=“daikanwa” code=“039047”>遠</gaiji>江、三河、駿河、甲斐、相模、伊豆 諸國、地大ニ震ヒ、瀕<gaiji
set=“daikanwa” code=“017503”>海</gaiji>ノ國ハ津浪ノ害ヲ<gaiji
set=“mojikyo” code=“075258”>蒙</gaiji>リ、就中伊勢國大湊ニテハ家千軒押シ流サレ五千人<gaiji set=“daikanwa”
code=“017990”>溺</gaiji>死ス、マタ鎌倉由比浜ニテハ水勢大佛
殿ニ及ビ二百人<gaiji set=“daikanwa” code=“017990”>溺</gaiji>
死セリ、是日、都、奈良及ビ陸奥國<gaiji set=“mojikyo”
code=“066797”>會</gaiji>津モ強ク震ヒ、・・・・・・・

Example of My-Database (cont.)
Field
Attributes

Upload Data

Languages

Example of My-Database (cont.)

Data Upload Processes

Example of My-Database (cont.)

Data Retrieval Example

Example of My-Database (cont.)

Spatiotemporal Retrieval Example

REST-Like API
Browser
User cannot change retrieval
procedures, user interfaces etc.

Controller

View
Model

Databases

ServerBrowser

Model
Controller

View

Controller
View
Controller REST-Like API
View
Controller
View
Model
Model
Model
Databases
Databases Server
Databases Server
Server Separation of server functions and user functions
 Server functions: Data repository and basic retrieval
 User function: retrieval procedure/algorithm and/or user interface

Usage of REST-Like API
Web Service
URI/GET/POST/ＸML
Database A
Query 1Result 1

Database B

Query 2User Side
Retrieval Algorithm

Result 2

Query 3
Database C
Result 3

JavaScript, Ruby, Python etc.
XSLT, DOM etc.

Example of Rest-Like API
 Server SRU: Search/Retrieve via URL REST: Representational State Transfer (receives queries by HTTP GET method

and returns XML data) Query：CQL（Contextual Query Language）
BaseURI?parameterName=value[&parameterName=value]* Response： XML over HTTP Client Request：HTTP or TCP Response：DOM API

 Example: Mashup of Digital Gazetteer and Google Maps
 Server-side: Digital Gazetteer Database User-side: Java Script

Query<?xml version="1.0" encoding="UTF-8"?>
Command<?xml-stylesheet type="text/xsl“
href="./SampleStyle.xsl"?><test:Places xmlns:test="urn:test"><test:DBName>G0000016pdic</test:DBName><test:RecordPath>togo/vol/item</test:RecordPath><test:PlaceName>%e7%9b%b8%e5%9b%bd%e5%af%ba</test:
PlaceName></test:Places>

Example of RestLike API (cont.)
Digital Gazetteer DB<?xml version="1.0" encoding="UTF-8"?><xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:test="urn:test">

GET-QueryXSLT (program)<xsl:output method="html" encoding="UTF-8" media-type="text/html"/><xsl:variable name="MapBaseURL">http://area.net.cias.kyoto-u.ac.jp/infolib/meta/search</xsl:variable><xsl:variable name="AccessURL"><xsl:value-of select="$MapBaseURL"/><xsl:text>?opendb=</xsl:text><xsl:value-of select="/test:Places/test:DBName"/><xsl:text>&amp;q=</xsl:text><xsl:value-of select="/test:Places/test:PlaceName"/><xsl:text>&amp;format=xml</xsl:text></xsl:variable><xsl:variable name="PlaceData" select="document('http://area.net.cias.kyotou.ac.jp/infolib/meta/search?opendb=G0000016pdic&amp;q=%e7%9b%b8%e5%9b%bd%e5%af%ba&amp;format=xml')/togo/vol/item"/><!--xsl:variable name="PlaceData" select="document($AccessURL)/togo/vol/item"/--><!--xsl:variable name="PlaceData" select="document('./search.xml')/togo/vol/item"/--><xsl:variable name="title">地名辞書RESTサービスサンプル</xsl:variable>

XML-Response<xsl:template match="/"><html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title><xsl:value-of select="$title"/></title><!--Google Map API--><meta name="viewport" content="initial-scale=1.0, user-scalable=no" /><script type="text/javascript"
src="http://maps.google.com/maps/api/js?sensor=false"></script><script type="text/javascript">function initialize() {JavaScriptGoogle<xsl:for-each select="$PlaceData"><xsl:if test="number(lat2) >= 0">
var centerPos = new google.maps.LatLng(<xsl:apply-templates select="lat2"/>,<xsl:apply-templates select="long2"/>)</xsl:if></xsl:for-each><?xml version="1.0" encoding="UTF-8"?><togo><vol><item pid="10026682"><country>山城</country><county reading="カミキョウ">上京</county><placeName reading="ソウコクジ">相国寺</placeName><pname1>京都市上京区</pname1><pname2/><pname3/><proma1>so^kokuji</proma1><proma2>sokokuji</proma2><proma3>so^kokuji</proma3><proma4>so^kokuji</proma4><proma5>soukokuji</proma5><proma6>soukokuzi</proma6><proma7>so^kokuzi</proma7><shp>1</shp><loc>1</loc><lat>35.2.0</lat><long>135.45.46</long>

Resultvar mapOptions = {zoom : 5,center : centerPos,
mapTypeId: google.maps.MapTypeId.ROADMAP};var map = new google.maps.Map(document.getElementById("google_map"), mapOptions);<xsl:for-each select="$PlaceData"><xsl:variable name="PName"><xsl:text>Pos</xsl:text><xsl:value-of select="position()"/></xsl:variable><xsl:variable name="MName"><xsl:text>markerOptons</xsl:text><xsl:value-of select="position()"/></xsl:variable><xsl:if test="number(lat2) >= 0">
var <xsl:value-of select="$PName"/> = new google.maps.LatLng(<xsl:apply-templates select="lat2"/>,<xsl:apply-templates select="long2"/>)
var <xsl:value-of select="$MName"/> = {position : <xsl:value-of select="$PName"/>,title: <xsl:text>'</xsl:text><xsl:apply-templates select="placeName"/> (<xsl:apply-templates select="lat2"/>,<xsl:apply-templates select="long2"/>)<xsl:text>'</xsl:text>,
map : map};
var marker = new google.maps.Marker(<xsl:value-of select="$MName"/>);</xsl:if></xsl:for-each>}</script><!--Google Map API--></head><body onload="initialize()"><xsl:apply-templates /><br/><div id="google_map" style="width:500px;height:500px"></div></body></html></xsl:template><xsl:template match="test:Places"><div class="title"><xsl:value-of select="$title"/></div><hr/><div class="main"><table border="1"><tr><th>ID</th><th>地名</th><th>国名</th><th>群名</th></tr><xsl:for-each select="$PlaceData"><xsl:apply-templates select="."/></xsl:for-each></table></div></xsl:template><xsl:template match="item"><xsl:if test="number(lat2) >= 0"><tr><td><xsl:value-of select="@pid"/></td><td><xsl:apply-templates select="placeName"/></td><td><xsl:apply-templates select="country"/></td><td><xsl:apply-templates select="county"/></td></tr></xsl:if></xsl:template></xsl:stylesheet>HTML-Table

Google Maps

Road Map of System Development
 Phase 1: Who and What Digitization

Search for
Resources Creating Databases
 Search/Retrieval of Databases
 Resource Sharing Systems

 Phase 2: When and Where Description of spatiotemporal attributes

Resource Sharing
SystemBibliography

Analysis ofContents

 Visualizing data in spatiotemporal context
 Analysis of contents by spatiotemporal attributes
 Spatiotemporal model and tools

Spatiotemporal
Systems

Spatiotemporal Info.

• Overlay variety of maps, images, calendars etc.
• Visualization, simulation, data mining etc.

Gazetteers etc.

 Phase 3: Ontology
 Linking everything Knowledge management Knowledge discoveries

Ontology
Knowledge
Discoveries

Vocabularies
Dictionaries
MarkupTOPICMAPS etc