UsingOntoBuilderforOntologyCreation.docx
- 文档编号:24630825
- 上传时间:2023-05-29
- 格式:DOCX
- 页数:12
- 大小:600.04KB
UsingOntoBuilderforOntologyCreation.docx
《UsingOntoBuilderforOntologyCreation.docx》由会员分享,可在线阅读,更多相关《UsingOntoBuilderforOntologyCreation.docx(12页珍藏版)》请在冰豆网上搜索。
UsingOntoBuilderforOntologyCreation
UsingOntoBuilderforOntologyCreation
Author:
GiovanniModica
Date:
10/25/2018
1.BrowsingFeaturesofOntoBuilder
OntoBuilderwasdesignedtoworklikeawebbrowser.Figure1showstheOntoBuilderbrowserinterface.TonavigatetoapagesimplyentertheURLintotheaddressbar(e.g.)andpressenterorclickthe“Go”button.BydefaultOntoBuilderwillusetheHTTPprotocolwhennoprotocolisspecified,soaURLsuchaswillbeautomaticallychangedto.URLscanalsobeenteredbymeansofcommoncopy/pastecommandseitherbyrightclickingontheaddressbarorusingthehot-keysshortcuts;theseshortcutsarecompatiblewiththeMSWindowsstandards(e.g.crtl-Cforcopy,crtl-Vforpaste,etc.).
Figure1.TheOntoBuilderbrowserinterface.
Oncethe“Go”buttonisclicked,theHTMLpageassociatedwiththeURLwillbedisplayedinthe“HTMLView”panel.OntoBuildermaintainsahistoryofvisitedURLs,whichcanbeaccessedusingacomboboxlistintheaddressbar.Theusercanusethebackwardsandforwardsbuttonsinthetoolboxtonavigatethehistory.Thenumberofentriesinthehistoryislimitedbyanoptioninthetooloptionsdialogasshowninfigure2.Thehistorycanbecleared(allentriesinthehistorywillbedeleted)byclickinginthe“ClearHistory”button.
Figure2.OntoBuilderbrowseroptions.
Othernavigationalaspectscanalsobesetinthe“Browser”optionstab.The“AutomaticMETAnavigation”optionisforpagescontainingredirectionMETAtagssuchasthefollowing:
BycheckingthisoptionOntoBuilderwillautomaticallyloadtheURLspecifiedintheURLattributefortheMETAtag. TheconnectiontimeoutindicatestheamountoftimetowaitbeforeabandoningaURLconnection.Byspecifying-1sec.,OntoBuilderwillusethesystemdefaultconnectiontimeout.Thisoptionisveryusefulforslowconnectionlinks. OntoBuildercanalsobedirectedtouseaProxyserverforInternetconnection.Byspecifyingaproxyhostandport,OntoBuilderwillretrieveHTMLpagesthroughtheproxyinsteadofadirectconnection(thedefault).ThisoptionisveryusefulifrunningOntoBuilderbehindfirewalls. OntoBuilderhassupportforHTMLcookies,howevercookiesdonotpersistoutsideOntoBuilderwizardsessions.Thismeansthatcookiesarepersistentwhileretrievinganontologyusingtheontologycreationwizard,butoncethewizardfinishestheontologygeneration,anycookieinformationwillbelost. 2.GeneratingOntologies OncethewebpageforwhichwewanttoextracttheontologyfromisloadedinOntoBuilder,wecanlaunchthe“OntologyCreationWizard”byselectingtheappropriatesubmenucommandunderthe“Ontology”menu,orbyclickingtheappropriateiconintheapplicationtoolbox,orbyusingthehot-keycrtl-W.Inordertoshowhowthewizardworkswewillbuildamulti-page(bymulti-pageontologywemeananontologythatisspreadacrossmultiplepages)ontologyfortheAwebsite.Thefirststepofthewizardisshowninfigure3. Figure3.Thefirststepoftheontologywizard. TheontologytitledefaultstothetitleoftheHTMLpageandtheontologynamedefaultstothehostfromwheretheHTMLpageisretrieved.Byclickinginthe“Next: buttonweopenthe“FormSelection”dialogasshowninfigure4.InthisdialogOntoBuilderwillshowalltheHTMLformsoftheHTMLalongwiththeirinputelements.Sinceonlyoneformcanbesubmittedatatimewhilebrowsingawebpage,theuserisrequiredtoselecttheformhe/shewantstosubmitfromtheformslistedunderthe“
Byclickingonanodeinthe“HTMLElements”panel,alltheattributes(defaultvalue,label,etc.)fortheelementrepresentedareshowninthe“Properties”panelinthelowerleft.IsworthnotingthatforHTMLframepages,theFORMelementswillbelocatedunderthe“”nodeinthe“HTMLElements”panel.
Figure4.The“FormSelection”wizarddialog
The“FormPreview”paneliswheretheuserwillentertherequiredvaluesforformsubmission.InordertodeterminewhattherequiredfieldsarewesuggestsimulatingtheprocessononeoftheInternetbrowserssuchasMSInternetExplorerorNetscapeNavigator.Figure5showstheminimumrequiredvaluesforourAexample.
Figure5.ThereservationprocessinA
ThesameprocessmustbesimulatedinOntoBuilder.Figure6showstheequivalentreservationinOntoBuilder.TheonlydifferenceisthatOntoBuilderdoesn’tsubmittheformbyclickingontheformsubmissionbutton,butinsteadbyclickingthe“Next”buttoninthewizard.
Figure6.ThereservationprocessinOntoBuilder
FailingtodothecorrectsimulationinOntoBuilderwillproduceunexpectedresults(mostofthetimesthewebsitewillreturnapageindicatingthatsomeinformationismissingorreturnanerrorpagewithabriefdescription).Generallyspeaking,whenusingOntoBuildertoretrieveanontologyfromawebapplication,theusermustsimulatetheuserinteractionasifworkinginacommonbrowser.
Returningtoourexample,therestofthewizardformsarethesame,excepttheywillcontainnewformelementstobeaddedtothefinalontology.Therestoftheprocessisverystraightforwardsowewilljustmentionhowtogettotheend.Therearefourmorepages(i.e.threemorewizarddialogs)toretrievethewholeontology,andinallfourpagesthereisnorequiredfields,defaultvalueswillbeenough.Alltheuserisrequiredtodoistoselecttheappropriateformonthe“HTMLElements”panelandsimulatetheformsubmissionbyclickingonthe“Continue”buttonineachofthenextthreepages.ThelastpagewillallowtoactuallymakethecarreservationinAvis,asshowninfigure7.
Figure7.Laststepintheontologycreationwizard
Duringthewizardoperationtheusercanusethe“Back”buttontogothepreviouslysubmittedform,incaseamistakewasdetected.Oncefinished,thewizardwilldisplaythegeneratedontologyonthe“MainPanel”,asdepictedinfigure8.Thegeneratedontologycanbesavedindifferentformatsbytheappropriatecommandsinthe“File”menu.
Figure8.Thegeneratedontology
3.EnteringtheRightURLsinOntoBuilder
Sometimes,enteringthesameURLusinginacommonbrowserintoOntoBuilderisnotthemostappropriatethingtodo.DuetoOntoBuilderlimitedHTMLrenderingcapabilities,someURLsmaynotbecorrectlydisplayed(andthus,difficulttonavigate).
Asanexample,considertheAwebsite.ByenteringinOntoBuilderwewillseethatitdoesabadjobinrenderingtheHTMLpage(seefigure9).NoontologywillbegeneratedfromsuchURL.ItisworthnothingthatnotalwaysabadrenderingoftheHTMLpagemeansthatnousefulontologycouldbegenerated,sometimesOntoBuilderhastroublerenderingtheHTMLpagebutthesourcecodeofitisretrievedcorrectly.Isrecommendedtoruntheontologycreationwizardevenifabadrenderingoccurs,inmostcasesthewizardwillidentifytheformelementseveniftheHTMLrenderingdidn’twork.
Figure9.AnexampleofbadHTMLrenderinginOntoBuilder
Inthesecases,itisadvisedtouseanInternetbrowsertoactuallynavigatetothepagewhereontologicalstructuresmaybeidentified.InthecaseofA,byclickinginthe“Rates&Reservations”buttoninthemenuthebrowserwilldisplaythereservationformundertheURL.Figure10showshowthistimeOntoBuildercorrectlyidentifiestheformelementsinthepage.
Figure10.AnexampleofcorrectHTMLrenderinginOntoBuilder
ForHTMLpagescontainingframes,itmaybeusefulto“break”theframesusingtheURLintheframeset.Asanexample,theURLisaHTMLpagecontainingframes(seetheemptyspaceintheuppersectionofthepageinfigure10)anditssourceisthefollowing:
InthiscaseitmaybebettertoentertheURLforthemainFrameframe(i.e.inOntoBuilder,thus“breaking”theframe.AlthoughOntoBuilderisdesignedtosupportframes(foranexampleloadtheNationalCwebsitetoseethreelevelsofframescorrectlyhandledbyOntoBuilder),wesuggesttofollowthepreviouspointswhendealingwithframes. MostcommonInternetbrowserswillallowtoseethesourceofanHTMLpage.ByusingOntoBuilderyoucanenablethe“SourcePanel”tabtoseetheHTMLsourceoftheloadedpage.Forthis,checkthe“SourcePanel”checkboxinthe“View”taboftheOntoBuilderoptionsdialog. Figure11.ViewoptionsforOntoBuilder 4.TroubleshootingOntologyGeneration NotallthewebsitesrunassmoothlyastheAsite.Changesareyouwillnotgetacleanontologyatthefirstrun.ThisisduetothecomplexityofmostwebsitesdesignedusingtechnologiesnotsupportedbyOntoBuilder.AtthistimeOntoBuilderdoesn’tsupportanyscriptingatall.Currentwebsitesrelyonscriptingforvalidation,automaticfieldfilling,etc.AsanexampleconsiderapagethathastwofieldsPickupLocationandDropoffLocation,eachwithanassignedhiddenfield.ByusingscriptingthewebpageautomaticallyassignsthekeywordsameinthehiddenfieldfortheDropoffLocation,indicatingthatthedropofflocationwillbethesameofthepickuplocation.AllthisistransparenttotheuserandalsotoOntoBuilder.Ifth
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- UsingOntoBuilderforOntologyCreation
![提示](https://static.bdocx.com/images/bang_tan.gif)