Tong Quan Ve Ontology

  • Published on
    29-Jul-2015

  • View
    403

  • Download
    10

Embed Size (px)

Transcript

<p>i Hc Quc Gia Thnh Ph H Ch Minh</p> <p>Trng i Hc Cng Ngh Thng Tin</p> <p>Tng Quan V OntologyK Thut Lp Trnh Trnh Tr Tu Nhn ToLp: CNTN02 GVHD: TS. Nguyn Tun ng SVTH: Nguyn Hu Nht MSSV: 07520437</p> <p>Mc Lc1. Tng quan v Ontology ...........................................................................................2 2. Thnh phn ca mt Ontology ................................................................................2 2.1 Cc c th .........................................................................................................3 2.2 Cc lp ..............................................................................................................3 2.3 Cc thuc tnh ...................................................................................................4 2.4 Cc mi quan h ...............................................................................................4 3. Phn loi Ontology .................................................................................................4 4. Phng php xy dng Ontology ...........................................................................5 4.1 Xc nh min quan tm v phm vi ca Ontology ..........................................6 4.2 Xem xt vic k tha cc Ontology c sn .......................................................6 4.3 Lit k cc thut ng quan trng trong Ontology ............................................7 4.4 Xy dng cc lp v cu trc lp phn cp ......................................................7 4.5 nh ngha cc thuc tnh v quan h cho lp .................................................8 4.6 nh ngha cc rng buc v thuc tnh v quan h ca lp ............................8 4.7 To cc thc th cho lp ..................................................................................9 5. Ngn ng Ontology ................................................................................................9 5.1 RDF ...................................................................................................................9 5.2 RDFS ...............................................................................................................10 5.3 OWL ................................................................................................................14 5.4 DAML+OIL .......................................................................................................16 6. Cng c pht trin Ontology .................................................................................16 6.1 Protg ............................................................................................................16 6.2 Chimaera .........................................................................................................18 6.3 KAON ...............................................................................................................18 7. Ti liu tham kho .................................................................................................20</p> <p>1</p> <p>1. Tng quan v Ontology:Thut ng Ontology xut hin t rt sm. Trong cun sch Siu hnh (Metaphysics) ca mnh, Aristotle nh ngha: Ontology l mt nhnh ca trit hc, lin quan n s tn ti v bn cht cc s vt trong thc t. Hay ni cch khc, i tng nghin cu ch yu ca Ontology xoay quanh vic phn loi cc s vt da trn cc c im mang tnh bn cht ca n. Ontology l mt thut ng mn t trit hc c tm dch l bn th hc, nhm ch khoa hc m t cc loi thc th trong th gii thc v cch chng lin kt vi nhau. Trong ngnh khoa hc my tnh v khoa hc thng tin, Ontology mang ngha l cc loi vt v quan h gia chng trong mt h thng hay ng cnh cn quan tm. Cc loi vt ny cn c gi l khi nim, thut ng hay t vng c th c s dng trong mt lnh vc chuyn mn no . Ontology cng c th hiu l mt ngn ng hay mt tp cc quy tc c dng xy dng mt h thng Ontology. Mt h thng Ontology nh ngha mt tp cc t vng mang tnh ph bin trong lnh vc chuyn mn no v quan h gia chng. S nh ngha ny c th c hiu bi c con ngi ln my tnh. Mt cch khi qut, c th hiu Ontology l "mt biu din ca s khi nim ho chung c chia s" ca mt min hay lnh vc nht nh. N cung cp mt b t vng chung bao gm cc khi nim, cc thuc tnh quan trng v cc nh ngha v cc khi nim v cc thuc tnh ny. Ngoi b t vng, Ontology cn cung cp cc rng buc, i khi cc rng buc ny c coi nh cc gi nh c s v ngha mong mun ca b t vng, n c s dng trong mt lnh vc m c th c giao tip gia ngi v cc h thng ng dng phn tn khc. Ontology c s dng trong tr tu nhn to, cng ngh Web ng ngha (Semantic Web), cc h thng k thut, k thut phn mm, tin hc y sinh v kin trc thng tin nh l mt hnh thc biu din tri thc v th gii hoc mt s lnh vc c th. Vic to ra cc lnh vc v Ontology cng l c s nh ngha v s dng ca c cu mt t chc kin trc(an enterprise architecture framework).</p> <p>2. Thnh phn ca mt Ontology:Cc thnh phn thng gp ca Ontology bao gm: </p> <p>Cc c th(individuals): cc thc th hoc cc i tng (cc i tng c bn hoc cp nn). Cc lp(classes): cc tp hp, cc b su tp, cc khi nim, cc loi i tng, hoc cc loi khc. Cc thuc tnh(attributes): cc kha cnh, c tnh, tnh nng, c im, hoc cc thng s m cc i tng (v cc lp) c th c. Cc quan h(relations): cch thc m cc lp v cc c th c th lin kt vi nhau. Cc thut ng chc nng(function terms): cu trc phc tp c hnh thnh t cc mi quan h nht nh c th c s dng thay cho mt thut ng c th trong mt bo co(statement). Cc s hn ch(restrictions): nhng m t chnh thc c tuyn b v nhng iu phi chnh xc cho mt s khng nh c chp nhn u vo. Cc quy tc(rules): tuyn b c hnh thc nh mt cp nu-th (if-then) m t suy lun logic c th c rt ra t mt s khng nh trong tng hnh thc ring. Cc tin (axioms): cc khng nh (bao gm cc quy tc) trong mt hnh thc hp l vi nhau bao gm cc l thuyt tng th m ontology m t trong lnh vc ca ng dng.</p> <p>2</p> <p>Cc s kin(events): s thay i cc thuc tnh hoc cc mi quan h. Sau y chng ta s tm hiu mt s thnh phn quan trng nht ca mt Ontology.</p> <p>2.1 Cc c th (Individuals):Cc c th l cc thnh phn c bn, nn tng ca mt ontology. Cc c th trong mt ontology c th bao gm cc i tng c th nh con ngi, ng vt, ci bn cng nh cc c th tru tng nh cc thnh vin hay cc t. Mt ontology c th khng cn bt k mt c th no, nhng mt trong nhng l do chnh ca mt ontology l cung cp mt ng ngha ca vic phn lp cc c th, mc d cc c th ny khng thc s l mt phn ca ontology.</p> <p>2.2 Cc lp (Classes):Cc lp l cc nhm, tp hp cc i tng tru tng. Chng c th cha cc c th, cc lp khc, hay l s phi hp ca c hai. Mt s v d v cc lp hc: </p> <p>Ngi (person), cc lp ca tt c mi ngi, hay i tng tru tng c th c m t bi cc tiu ch tr thnh mt con ngi. Phng tin xe c (vehicle), cc lp ca tt c cc phng tin xe c, hay i tng tru tng c th c m t bi cc tiu ch c mt phng tin xe c. Xe hi (cars), cc lp ca tt c cc xe t, hoc i tng tru tng c th c m t bi cc tiu ch c mt chic xe hi. Lp hc (class), i din cho lp ca tt c cc lp hc, hay i tng tru tng c th c m t bi cc tiu ch c mt lp hc. vt (Thing), i din cho lp ca tt c mi vt, hoc i tng tru tng c th c m t bi cc tiu ch c vt.</p> <p>Cc ontology bin i tu thuc vo cu trc v ni dung ca n: Mt lp c th cha cc lp con, c th l mt lp tng quan (cha tt c mi th), c th l lp ch cha nhng c th ring l, Mt lp c th xp gp vo hoc b xp gp vo bi cc lp khc. Mi quan h xp gp ny c s dng to ra mt cu trc c th bc cc lp, thng l vi mt lp thng dng nht trn nh v cc lp c kiu r rng c th pha di cng. V d m hnh phn lp xe hi nh hnh sau:</p> <p>Hnh M hnh phn lp xe hi.</p> <p>3</p> <p>Nu quy tc phn vng m bo rng mt xe duy nht khng th c hai lp, cc phn vng ny c gi l mt phn vng phn chia. Nu cc quy tc phn vng m bo rng mi i tng c th trong siu lp l mt th hin ca t nht mt trong cc lp phn vng, cc phn vng ny c gi l mt phn vng ton b.</p> <p>2.3 Cc thuc tnh (Attributes):Cc i tng trong ontology c th c m t thng qua vic khai bo cc thuc tnh ca chng. Mi mt thuc tnh u c tn v gi tr ca thuc tnh . Cc thuc tnh c s dng lu tr cc thng tin m i tng c th c. V d, i vi mt c nhn c th c cc thuc tnh: H tn, ngy sinh, qu qun, s CMND Gi tr ca mt thuc tnh c th l mt kiu d liu phc tp.</p> <p>2.4 Cc mi quan h (Relationships):Mi quan h (cn gi l quan h) gia cc i tng trong ontology nh r nh th no cc i tng ny c lin quan n cc i tng khc. c trng l mt mi quan h loi ring bit (hay lp) m quy nh c th trong chiu hng cc i tng ny c lin quan n cc i tng khc trong ontology. Ch yu sc mnh ca ontology n t kh nng m t cc mi quan h. Cng vi nhau, tp hp cc mi quan h m t ng ngha trong mt lnh vc no . Cc thit lp ca cc loi quan h c s dng(cc lp ca cc quan h) v h thng phn cp ca n m t sc mnh biu hin ca ngn ng trong ontology c th hin. Mt kiu quan h quan trng l kiu quan h xp gp (subsumption). Kiu quan h ny m t cc i tng no l cc thnh vin ca cc lp no ca cc i tng. Ontology c th phn bit gia cc loi khc nhau ca cc quan h. V d: </p> <p>loi quan h dnh cho cc quan h gia cc lp loi quan h dnh cho cc quan h gia cc c th loi quan h dnh cho cc quan h gia mt c th v mt lp loi quan h dnh cho cc quan h gia mt i tng n l v mt b su tp (collection) loi quan h dnh cho cc quan h gia cc b su tp</p> <p>Loi quan h i khi l mt lnh c trng v sau c dng lu tr cc loi c trng ca s kin hoc tr li tng loi cu hi ring bit. Nu cc nh ngha ca cc loi quan h c bao gm trong mt ontology, sau ontology nh ngha ring ngn ng ontology ca n.</p> <p>3. Phn loi Ontology:T khi bt u nghin cu v Ontology trong Khoa hc my tnh, Ontology c quan tm vi mong mun tng cng vic s dng li h thng c s tri thc bn trong, v n cng a ra nhiu dng Ontology m t kh nng khc nhau cho vic ti s dng h thng c s tri thc. S phn loi Ontology c th c to ra theo ch </p> <p>4Hnh Phn loi Onlotogy.</p> <p>ca s khi nim ha.Trong kha cnh ny, phn ct li nht c tng kt theo hnh bn cnh. Top-level Ontology: cn gi l Ontology lp cao, nhm din t nhng khi nim tng quan v tru tng c th c chia s qua nhiu lnh vc v ng dng. N mn cc nim trit hc m t nhng khi nim lp cao cho mi vt v s tn ti ca chng, nh i tng vt cht hay i tng tru tng nh l cc nim c c im chung v tri thc nhn thc thng thng v hin tng nh thi gian, khng gian, cc tin trnh ... Do s tng quan ca , n khng s dng trc tip trong cc ng dng, m thng qua cc Ontology khc. Domain Ontology v task Ontology: cc loi Ontology ny ly tri thc t trong nhng lnh vc xc nh, nh trong y khoa, a l hay tri thc v mt tc v ring bit nh s chn hoc s cu hnh. V mt tng th Ontology loi ny thu hp hn v xc nh hn so vi Top-level Ontology. S khi nim ha trong mt Domain Ontology l gi cc tc v c lp, khi nhng nim trong mt tc v Ontology c miu t khng c tnh cht r rt vi chi tit c th n mt lnh vc. S pht trin ca Domain Ontology c thc hin nhiu cc lnh vc: y hc, di truyn, a l, du lch, thng tin mi trng. Cn Task Ontology c pht minh cho cc tc v xy dng, sp xp k hoch lm vic, gim st trong mt lnh vc khoa hc, c s tri thc my tnh dy hc, s theo di phng tn la, cc tc v hng dn iu tr bnh ... Application Ontology: cng thu hp v phm vi, Application Ontology cung cp mt b t vng xc nh c yu cu m t s ban hnh cc tc v chc chn trong mt ng cnh ng dng c th. c bit, n s dng c Domain Ontology v Task Ontology v m t vai tr ca chng trong mt tc c th. Chng ta c th thy h thng phn cp ca Ontology thng qua s trnh by trn: Ontology lp thp hn k tha v chuyn mn ha cc khi nim v mi quan h t Ontology lp trn. Ontology lp thp c th hn v phm vi ng dng thu hp hn, cn Ontology lp cao c kh nng rng hn, ch yu dnh cho vic k tha v s dng li.</p> <p>4. Phng thc xy dng Ontology:C nhiu phng php khc nhau xy dng mt Ontology, nhng nhn chung cc phng php u thc hin hai bc c bn l: xy dng cu trc lp phn cp v nh ngha cc thuc tnh cho lp. Trong thc t, vic pht trin mt Ontology m t lnh vc cn quan tm l mt cng vic khng n gin, ph thuc rt nhiu vo cng c s dng, tnh cht, quy m, s thng xuyn bin i ca min cng nh cc quan h phc tp trong . Nhng kh khn ny i hi cng vic xy dng Ontology phi l mt qu trnh lp i lp li, mi ln lp ci thin, tinh ch v pht trin dn sn phm ch khng phi l mt quy trnh khung vi cc cng on tch ri nhau. Cng vic xy dng Ontology cng cn phi tnh n kh nng m rng lnh vc quan tm trong tng lai, kh nng k tha cc h thng Ontology c sn, cng nh tnhlinh ng Ontology c kh nng m t tt nht cc quan h phc tp trong th gii thc. Mt s nguyn tc c bn ca vic xy dng Ontology thng qua cc cng on sau y: Xc nh min quan tm v phm vi ca Ontology. Xem xt vic k tha cc Ontology c sn. Lit k cc thut ng quan trng trong Ontology. Xy dng cc lp v cu trc lp phn cp.</p> <p>5</p> <p>nh ngha cc thuc tnh v quan h cho lp. nh ngha cc rng buc v thuc tnh v quan h ca lp. To cc thc th cho lp.</p> <p>4.1 Xc nh lnh vc quan tm v phm vi ca Ontology:Thng thng, cc yu cu i vi mt h thng Ontology l m t lnh vc quan tm nhm phc v c s tri thc trong vic gii quyt nhng mc ch chuyn bit. Cng vic c t xc nh, phn tch, nhn din chnh xc yu cu c thc hin bng cch tr li nhng cu hi sau: Ontology cn m t lnh vc no? Ontology phc v cho mc ch chuyn bit g? C s tri thc trong Ontology s gii quyt nhng cu hi g? Ontology nhm vc v i tng no? Ai l ngi s xy dng, qun tr Ontology?</p> <p>Nhn chung, cu tr li cho cc cu hi dng ny c th s thng xuyn thay i trong sut qu trnh xy dng mt Ontology. Nht l khi c s thay i v mc ch hoc cn b sung tnh nng trong vic s dng c s tri thc. Tuy nhin, vic tr li chnh xc cc cu hi trn ti mi bc lp s gip gii hn phm vi ca m hnh cn m t v d tr cc k thut s s dng trong qu trnh pht trin. Ly v d, nu d tr kh nng xy ra s khc bit v ngn ng gia ngi pht trin v ngi s dng th Ontology phi c b sung c ch nh x (mapping)qua li cc thut ng gia cc ngn ng khc nhau. Hoc gi s Ontology cn xy dng c chc nng x l ngn ng t nhin, ng dng dch ti liu t ng th cng cn thit phi c k thut xc nh t ng ngha... Sau khi pht tho phm vi Ontology da trn vic tr li nhng cu hi trn, ngi thit k s tr li cc cu hi mang tnh nh gi, qua tip tc tinh chnh li phm vi ca h thng cn xy dng. Cc cu hi dng ny thng da trn c s tri thc ca Ontology v c gi l cu hi kim chng kh nng (competency question): Ontology c thng tin tr li cho cc cu hi c quan tm trn c s tri thc hay khng? Cu tr li ca c s tri thc p ng c mc , yu cu no ca ngi s dng? Cc rng buc v quan h phc tp trong min quan tm c biu din hp l cha</p> <p>4.2 Xem xt vic k tha cc Ontology c sn:y l mt cng on thng hay s dng gim thiu cng sc xy dng mt Ontology. Bng cch k tha cc Ontology tng t c sn, ngi xy dng c th thm hoc bt cc lp, quan h gia cc lp, thc th... tinh chnh ty theo mc ch ca mnh. Vic s dng li cc Ontology c sn cng rt quan trng khi cn s tng tc gia cc ng dng khc nhau, cc ng dng s cn phi hiu cc lp, thc th, quan h... ca nhau thun tin trong vic trao i hoc thng nht thng tin. Vn xy dng mt Ontology mi bng cch k tha cc h thng c sn lin quan n mt bi ton rt phc tp l trn (merging)cc Ontology. V d trong trng hp tn cc khi nim c nh ngha trong cc Ontology ny c th ging nhau trong khi chng c dng m t cc loi vt hon ton khc nhau, v cng c th xy ra trng hp ngc li, khi tn cc khi nim khc nhau nhng cng m t mt s vt, vmt vn na l lm th no b sung cc quan h, thuc tnh c sn vo mt h thng mi. Tuy nhin, hu ht cc Ontology s dng trong ngnh khoa hc my tnh ni chung v Web ng ngha ni ring u</p> <p>6</p> <p>c xy dng trn cc h thng xy dng v qun tr Ontology. Tn mt s cng c nh: Sesame, Protg, Ontolingua, Chimaera, OntoEdit, OidEd... Hin nay, a s cc phn mm ny u h tr chc nng t ng trn cc Ontology cng hoc thm ch khc nh dng vi nhau. Mc d vy, mc no , ngi xy dng cng cn phi kim tra li mt cch th cng, nhng y khng phi l mt cng vic phc tp. Hin c rt nhiu Ontology c chia s trn Web ni ting nh: UNSPSC (www.unspsc.org)do chng trnh pht trin ca Lin Hip Quc hp tc vi t chc Dun &amp; Bradstreet nhm cung cp cc thut ng ca cc sn phm v dch v thng mi. C...</p>