THE SEMANTIC WEB
AN INTRODUCTION
LUIGI DE RUSSIS
THE WEB IS A WEB OF DOCUMENT
FOR PEOPLE,NOT FOR MACHINES
THE WEB IS A WEB OF DOCUMENT
THE SEMANTIC WEB IS A WEB OF DATA
LinkingOpen Data cloud diagram,
by Richard Cyganiak and Anja Jentzsch.
http://lod-cloud....
LET’S THINK!
HOW TO GET DATA
FROM THE WEB?
HOW TO GET DATA FROM THE WEB?
DATA IS PRESENT ON SOME WEBSITES
Wikipedia,GitHub,Twitter,Facebook,…
HOW TO GET IT?
differen...
EXAMPLE
GITHUB
WebAPIs(thirdversion)
https://developer.github.com/v3
DataavailableinJSON
Authenticationisrequired formostc...
EXAMPLE
TWITTER
https://dev.twitter.com/docs/
Authenticationisrequired formostcalls
Limitationsaboutnumberofrequests
Dataa...
EXAMPLE
WIKIPEDIA
MediaWikiWebAPIs(version1.1)
http://www.mediawiki.org/wiki/API:Main_page
DataavailableinJSON,PHP,WDDX,XM...
HOW TO GET DATA FROM THE WEB?
DATA IS LOCKED IN “DATA ISLANDS”
Wikipedia,GitHub,Twitter,Facebook,…
LIMITED OR NO ACCESS TO...
DATA ON THE WEB IS NOT ENOUGH!
weneedaproperinfrastructure
DATA SHOULD BE AVAILABLE ON THE WEB
accessibleandstructuredvias...
DEFINITIONS
To a computer,theWeb is a flat,boring world, devoid of
meaning. This is a pity, as in factdocumentson theWeb
describereal ...
THE INTERNET,1994C.A.
NEW!
NEW!
NoGoogle,Wikipedia,Amazon,
…yet!
I have a dream for the Web [in which computers]become
capableof analyzing all thedata on the Web – thecontent,
links, and ...
THE SEMANTIC WEB IS A WEB OF DATA
THE SEMANTIC WEB IS THE WEB
samebasetechnologies,evolutionary,decentralized
IT IS ABOUT ...
WHAT IS THE RELATIONSHIP WITH AI?
INFLUENCE
SometechnologiesintheSemanticWebbenefitedalotfromAIresearch
anddevelopment(and...
FUNDAMENTALS
RESOURCE AND DESCRIPTION
RESOURCE
everydocument“reachable”ontheWeb
nomatterthecontent,format,language,etc.
RESOURCE DESCRI...
RESOURCE AND DESCRIPTION
Resources
RESOURCE AND DESCRIPTION
Description
RESOURCE AND DESCRIPTION
DescriptionTitle
Author
Date
Topic
Quality
Title Author
Date Topic
URIS
unambiguousnamesforresources
RDF
acommondatamodeltoconnectanddescriberesources
SPARQL
accesstothedatamodel
RDFS,OWL
c...
MODELING DATA
EXAMPLE:BOOKSTORE
RepresentthefollowingdataabouttheAIbookasasetof relations
Title:“ArtificialIntelligence:AModern
Approach...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594
Resource
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Literal
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
title
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Prentice Hall
Russel, Stuart
Nor...
RDF:RESOURCE DESCRIPTION FRAMEWORK
STRUCTURED IN STATEMENTS
SUBJECT
aresource(URI)
PREDICATE
averb,propertyorrelationship
...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Prentice Hall
Russel, Stuart
Nor...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
title
RDFIN XMLSYNTAX
<rdf:RDFxm...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
title
RDFIN TURTLE
<http://...is...
LINKIN’DATA
EXAMPLE:BOOKSTORE
RepresentthefollowingdataabouttheItaliantranslationoftheAIbook
asasetofrelations
Title:“Intelligenzaarti...
EXAMPLE:BOOKSTORE
http://...isbn/9788871925936
Intelligenza Artificiale. Un
approccio moderno
Prentice Hall
Russel, Stuart...
EXAMPLE:BOOKSTORE
http://...isbn/9788871925936
Intelligenza Artificiale. Un
approccio moderno
Prentice Hall
title
publishe...
EXAMPLE:BOOKSTORE
http://...isbn/9788871925936
Intelligenza Artificiale. Un
approccio moderno
Prentice Hall
title
publishe...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Prentice Hall
Russel, Stuart
Nor...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Prentice Hall
Russel, Stuart
Nor...
PROBLEM:FIELD NAMES ARE ARBITRARY
Synonyms:authororcreatorormakerorcontributoror…
Singularorplural:authororauthors
SOLUTIO...
DUBLIN CORE
GENERAL VOCABULARY
DublinCoreMetadataInitiative(DCMI)
http://dublincore.org
BUILDING BLOCKS TO DEFINE METADATA...
PROBLEM:FIELD VALUES ARE ARBITRARY
Valuetype:string,date,integer,…
Valueformat:“Norvig,Peter”or“Norvig,P.”or“PeterNorvig”o...
FRIEND OF AFRIEND (FOAF)
GENERAL ONTOLOGY
Describepersons,theiractivitiesandtheirrelationstootherpeopleand
objects
http://...
EXAMPLE:BOOKSTORE
http://...isbn/9780136042594 Artificial Intelligence: A Modern
Approach
Prentice Hall
Russel, Stuart
Nor...
http://...isbn/9780136042594
Norvig, Peter
dc:creator
foaf:name
http://...isbn/9780136042594
Norvig, Peter
author
WHY?
RDFSCHEMA
RDFSCHEMA
SCHEMA
DefinitionofthenodesandpredicatesusedinaRDFdocument
DOMAIN AND RANGE
RDFSdescribespropertiesintermsofclas...
EXAMPLE
RDFdata
http://elite.polito.it/people/derussis
teaches
http://bit.ly/lingambmult
http://elite.polito.it/people/derussis
teaches
EXAMPLE
RDFdata
RDFschema
http://bit.ly/lingambmult
Teacher
Person
teaches ...
http://...isbn/9780136042594
Norvig, Peter
dc:creator
foaf:name
http://...isbn/9780136042594
Norvig, Peter
author
BACK TO ...
http://...isbn/9780136042594
Norvig, Peter
dc:creator
foaf:name
http://...isbn/9780136042594
Norvig, Peter
author
BACK TO ...
RDFSEXPRESSIVITY
SIMPLE RELATIONSHIP BETWEEN THINGS
RDFSprovidesavocabularytoexpressrelationshipbetweenthings
(e.g.,subCla...
OWL
WEB ONTOLOGY LANGUAGE
WHAT?
OWL(version2):aknowledgerepresentationlanguage
Designedtoformulate,exchangeandreasonwithknowle...
WEB ONTOLOGY LANGUAGE
INDIVIDUALS,CLASSES AND PROPERTIES
“PolitecnicodiTorinoisauniversity”
“PolitecnicodiTorinohasaprofes...
WEB ONTOLOGY LANGUAGE
EXPRESSIVITY
Designedtorepresentrichandcomplexknowledgeaboutthings,group
ofthings,andtheirrelations
...
WEB ONTOLOGY LANGUAGE
LINKED
OntologiesinOWLcanbepublishedontheWebandmay refertoorbe
referredfromotherOWLontologies
CHOOSE...
EXAMPLE:BOOKSTORE
Intelligenza Artificiale. Un
approccio moderno
Prentice Hall
dc:title
dc:publisher
Artificial Intelligen...
EXAMPLE:BOOKSTORE
Intelligenza Artificiale. Un
approccio moderno
Prentice Hall
dc:title
dc:publisher
Artificial Intelligen...
HANDS ON OWL
EXAMPLE:BOOKSTORE
Itistimetosellthebookswemodeled.
Usersmusthavethepossibilitytosearchinourbookcatalog.
Weneedtodescribeou...
EXAMPLE:BOOKSTORE
BUILD THE MODEL
1. Describethebusinessentity
2. Describetheoffereditems
3. Describetheoffer
4. Linktheof...
DESCRIBE THE BUSINESS ENTITY
default:BookStore_1
agr:BusinessEntity;
gr:legalName“bookstore.comLtd.”^^xsd:string.
Bookstor...
DESCRIBE THE OFFERED ITEMS
default:AIBook_en
aitem:Book,gr:ActualProductOrServiceInstance ;
item:hasTotalPagesdefault:Quan...
Bookstore_1 AIBook_en
item:BookQuantitativeValue
Integer_1
1132
gr:ActualProductOrServiceInstance
gr:ProductOrService
rdf:...
DESCRIBE THE OFFER
default:Offering_1
agr:Offering ;
gr:hasBusinessFunctiongr:Sell;
gr:hasPriceSpecificationdefault:UnityP...
Bookstore_1
Offering_1
TypeAndQuantity
Node_1UnitPriceSpecification_1
AIBook_en
item:BookQuantitativeValue
Integer_1
gr:Se...
DESCRIBE THE OFFER
default:TypeAndQuantityNode_1
agr:TypeAndQuantityNode ;
gr:amountOfThisGood“1.0”^^xsd:float;
gr:typeOfG...
Bookstore_1
Offering_1
TypeAndQuantity
Node_1UnitPriceSpecification_1
AIBook_en
item:BookQuantitativeValue
Integer_1
gr:Se...
default:BookStore_1gr:offersdefault:Offering_1
LINK THE OFFER TO THE BUSINESS ENTITY
Bookstore_1
Offering_1
TypeAndQuantity
Node_1UnitPriceSpecification_1
AIBook_en
item:BookQuantitativeValue
Integer_1
gr:Se...
QUERY THE WHOLE!
PREFIXgr:<http://purl.org/goodrelations/v1#>
PREFIXitem:<http://www.elite.polito.it/ontologies/example/it...
QUERY THE WHOLE!
?itemrdf:typeitem:Book.
SPARQL
?item
item:Book
rdf:type
QUERY THE WHOLE!
?objectgr:typeOfGood?item.
SPARQL
?object
AIBook_en
item:Book
gr:typeOfGood
rdf:type
QUERY THE WHOLE!
?offeringgr:includesObject?object.
SPARQL
?offering
TypeAndQuantity
Node_1
AIBook_en
item:Book
gr:include...
QUERY THE WHOLE!
?offeringrdf:typegr:Offering.
SPARQL
?offering
TypeAndQuantity
Node_1
AIBook_en
item:Book
gr:includeObjec...
QUERY THE WHOLE!
SELECT?offering
SPARQL
Offering_1
TypeAndQuantity
Node_1
AIBook_en
item:Book
gr:includeObject
gr:typeOfGo...
REFERENCES
SemanticWebstandards:http://w3c.org/standards/semanticweb
SemanticWebWiki:http://semanticweb.org
SemanticWebFAQ...
THANKS!
LuigiDeRussis
http://elite.polito.it
LICENSE
ThisworkislicensedundertheCreativeCommons“Attribution-NonCommercial-
ShareAlikeUnported(CCBY-NC-SA3,0)”License.
Yo...
Upcoming SlideShare
Loading in …5
×

Semantic Web: an introduction

737 views

Published on

Short seminar about the Semantic Web for the "Artificial Intelligence" course at Politecnico di Torino (academic year 2013/2014)

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
737
On SlideShare
0
From Embeds
0
Number of Embeds
105
Actions
Shares
0
Downloads
11
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Semantic Web: an introduction

  1. 1. THE SEMANTIC WEB AN INTRODUCTION LUIGI DE RUSSIS
  2. 2. THE WEB IS A WEB OF DOCUMENT FOR PEOPLE,NOT FOR MACHINES
  3. 3. THE WEB IS A WEB OF DOCUMENT
  4. 4. THE SEMANTIC WEB IS A WEB OF DATA LinkingOpen Data cloud diagram, by Richard Cyganiak and Anja Jentzsch. http://lod-cloud.net/
  5. 5. LET’S THINK!
  6. 6. HOW TO GET DATA FROM THE WEB?
  7. 7. HOW TO GET DATA FROM THE WEB? DATA IS PRESENT ON SOME WEBSITES Wikipedia,GitHub,Twitter,Facebook,… HOW TO GET IT? different,evolvingandproprietaryWebAPIs variousdataexchangeformats
  8. 8. EXAMPLE GITHUB WebAPIs(thirdversion) https://developer.github.com/v3 DataavailableinJSON Authenticationisrequired formostcalls
  9. 9. EXAMPLE TWITTER https://dev.twitter.com/docs/ Authenticationisrequired formostcalls Limitationsaboutnumberofrequests DataavailableinJSON RESTfulWebAPIs(version1.1) StreamingAPIs(version1.1)
  10. 10. EXAMPLE WIKIPEDIA MediaWikiWebAPIs(version1.1) http://www.mediawiki.org/wiki/API:Main_page DataavailableinJSON,PHP,WDDX,XML,YAML,TXT,… RSS DirectXMLexports
  11. 11. HOW TO GET DATA FROM THE WEB? DATA IS LOCKED IN “DATA ISLANDS” Wikipedia,GitHub,Twitter,Facebook,… LIMITED OR NO ACCESS TO THIS DATA different,evolvingandproprietaryWebAPIs variousdataexchangeformats
  12. 12. DATA ON THE WEB IS NOT ENOUGH! weneedaproperinfrastructure DATA SHOULD BE AVAILABLE ON THE WEB accessibleandstructuredviastandardWebtechnologies notcontrolledbyapplications,only DATA SHOULD BE INTERLINKED OVER THE WEB i.e.,datacanbeintegratedovertheWeb THIS IS WHERE SEMANTIC WEB COME IN
  13. 13. DEFINITIONS
  14. 14. To a computer,theWeb is a flat,boring world, devoid of meaning. This is a pity, as in factdocumentson theWeb describereal objects and imaginary concepts.[…] Adding semanticstothe Web involvestwothings: allowing documents which have informationin machine-readable forms, and allowing links tobe createdwith relationship values. Only when we have this extra level of semanticswe will be able touse computerpower tohelp us exploit the information toa greaterextent than our own reading. TIM BERNERS-LEE,1994
  15. 15. THE INTERNET,1994C.A. NEW! NEW! NoGoogle,Wikipedia,Amazon, …yet!
  16. 16. I have a dream for the Web [in which computers]become capableof analyzing all thedata on the Web – thecontent, links, and transactionbetweenpeople and computers. A “SemanticWeb”, which should make thispossible, has yet to emerge, but when it does, the day-to-day mechanismsof trade, bureaucracy and our daily lives will be handled by machinestalking to machines.The“intelligentagents”people have toutedfor ages will finally materialize. TIM BERNERS-LEE,1999 Weaving the Web–The OriginalDesign and Ultimate Destiny of the WorldWideWebby Its Inventor. Tim Berners-Lee,HarperSan Francisco,September1999
  17. 17. THE SEMANTIC WEB IS A WEB OF DATA THE SEMANTIC WEB IS THE WEB samebasetechnologies,evolutionary,decentralized IT IS ABOUT COMMON FORMATS forintegrationandcombinationofdatadrawnfromdiversesources IT IS ABOUT A LANGUAGE forrecordinghowthedatarelatestorealworldobjects
  18. 18. WHAT IS THE RELATIONSHIP WITH AI? INFLUENCE SometechnologiesintheSemanticWebbenefitedalotfromAIresearch anddevelopment(andviceversa) DIFFERENT GOALS ArtificialIntelligenceapproach:buildsmartermachines,teach computerstoinferthemeaningofdata SemanticWebapproach:havesmarterdata,makedataeasierfor machinestofind,accessandprocess
  19. 19. FUNDAMENTALS
  20. 20. RESOURCE AND DESCRIPTION RESOURCE everydocument“reachable”ontheWeb nomatterthecontent,format,language,etc. RESOURCE DESCRIPTION independentfromtheformat standardlanguage(basedonmetadata)
  21. 21. RESOURCE AND DESCRIPTION Resources
  22. 22. RESOURCE AND DESCRIPTION Description
  23. 23. RESOURCE AND DESCRIPTION DescriptionTitle Author Date Topic Quality Title Author Date Topic
  24. 24. URIS unambiguousnamesforresources RDF acommondatamodeltoconnectanddescriberesources SPARQL accesstothedatamodel RDFS,OWL commondescriptionlanguages OWL,RIF reasoning(mainlylogicinference)
  25. 25. MODELING DATA
  26. 26. EXAMPLE:BOOKSTORE RepresentthefollowingdataabouttheAIbookasasetof relations Title:“ArtificialIntelligence:AModern Approach” Author:Russel,StuartandNorvig,Peter Publisher: PrenticeHall ISBN:978-0136042594
  27. 27. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Resource
  28. 28. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Literal
  29. 29. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach title
  30. 30. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall Russel, Stuart Norvig, Peter title publisher author author
  31. 31. RDF:RESOURCE DESCRIPTION FRAMEWORK STRUCTURED IN STATEMENTS SUBJECT aresource(URI) PREDICATE averb,propertyorrelationship OBJECT aresourceoraliteralstring
  32. 32. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall Russel, Stuart Norvig, Peter title publisher author author Subject Object Object Object Object Predicate Predicate Predicate
  33. 33. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach title RDFIN XMLSYNTAX <rdf:RDFxmlns:rdf=http://www.w3.org/…/22-rdf-syntax-ns#> <rdf:Descriptionabout=“http://...isbn/9780136042594”> <title>ArtificialIntelligence:AModernApproach</title> </rdf:Description> </RDF>
  34. 34. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach title RDFIN TURTLE <http://...isbn/9780136042594> title“ArtificialIntelligence:AModernApproach”
  35. 35. LINKIN’DATA
  36. 36. EXAMPLE:BOOKSTORE RepresentthefollowingdataabouttheItaliantranslationoftheAIbook asasetofrelations Title:“Intelligenzaartificiale.Unapproccio moderno” Author:Russel,StuartandNorvig,Peter Publisher: PrenticeHall ISBN:978-8871925936 OriginalISBN:978-0136042594
  37. 37. EXAMPLE:BOOKSTORE http://...isbn/9788871925936 Intelligenza Artificiale. Un approccio moderno Prentice Hall Russel, Stuart Norvig, Peter title publisher creator creator http://...isbn/9780136042594 original
  38. 38. EXAMPLE:BOOKSTORE http://...isbn/9788871925936 Intelligenza Artificiale. Un approccio moderno Prentice Hall title publisher http://...isbn/9780136042594 original http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall title publisher
  39. 39. EXAMPLE:BOOKSTORE http://...isbn/9788871925936 Intelligenza Artificiale. Un approccio moderno Prentice Hall title publisher http://...isbn/9780136042594 original http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall title creator sameURI,sameresource
  40. 40. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall Russel, Stuart Norvig, Peter title publisher author author http://...isbn/9788871925936 Intelligenza Artificiale. Un approccio moderno Prentice Hall title publisher original Russel, Stuart Norvig, Peter creator creator
  41. 41. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall Russel, Stuart Norvig, Peter title publisher author author http://...isbn/9788871925936 Intelligenza Artificiale. Un approccio moderno Prentice Hall title publisher original Russel, Stuart Norvig, Peter creator creator Whataboutmergingcreatorandauthor? InRDF,itisnotpossible!
  42. 42. PROBLEM:FIELD NAMES ARE ARBITRARY Synonyms:authororcreatorormakerorcontributoror… Singularorplural:authororauthors SOLUTION:STANDARDS generalordomain-specific
  43. 43. DUBLIN CORE GENERAL VOCABULARY DublinCoreMetadataInitiative(DCMI) http://dublincore.org BUILDING BLOCKS TO DEFINE METADATA FOR THE SEMANTIC WEB Definetitle,contributor,publisher,license,date,language,etc.
  44. 44. PROBLEM:FIELD VALUES ARE ARBITRARY Valuetype:string,date,integer,… Valueformat:“Norvig,Peter”or“Norvig,P.”or“PeterNorvig”or… Valuerestrictions:onevalueormultiplevalues(howmany?) SOLUTIONS Standards Controlledvocabulary(closelistofterms) Semanticallyrichdescriptionstosupportsearch(RDFSand/orOWL)
  45. 45. FRIEND OF AFRIEND (FOAF) GENERAL ONTOLOGY Describepersons,theiractivitiesandtheirrelationstootherpeopleand objects http://www.foaf-project.org BUILDING BLOCKS TO DEFINE STRUCTURED RELATIONS BETWEEN PEOPLE Definename,familyName,givenName,knows,age,nick,etc.
  46. 46. EXAMPLE:BOOKSTORE http://...isbn/9780136042594 Artificial Intelligence: A Modern Approach Prentice Hall Russel, Stuart Norvig, Peter dc:title dc:publisher dc:creator dc:creator foaf:http://xmlns.com/foaf/spec dc:http://purl.org/dc/terms foaf:name foaf:name foaf:name
  47. 47. http://...isbn/9780136042594 Norvig, Peter dc:creator foaf:name http://...isbn/9780136042594 Norvig, Peter author WHY?
  48. 48. RDFSCHEMA
  49. 49. RDFSCHEMA SCHEMA DefinitionofthenodesandpredicatesusedinaRDFdocument DOMAIN AND RANGE RDFSdescribespropertiesintermsofclassesofresource towhichtheyapply(froma“domain”toa“range”)
  50. 50. EXAMPLE RDFdata http://elite.polito.it/people/derussis teaches http://bit.ly/lingambmult
  51. 51. http://elite.polito.it/people/derussis teaches EXAMPLE RDFdata RDFschema http://bit.ly/lingambmult Teacher Person teaches Course domain range subClassOf type type
  52. 52. http://...isbn/9780136042594 Norvig, Peter dc:creator foaf:name http://...isbn/9780136042594 Norvig, Peter author BACK TO THE BOOKSTORE EXAMPLE…
  53. 53. http://...isbn/9780136042594 Norvig, Peter dc:creator foaf:name http://...isbn/9780136042594 Norvig, Peter author BACK TO THE BOOKSTORE EXAMPLE… dc:creatorhasrangeAgent,i.e.,aclass(resource),notaliteral: weuseananonymousclassforthisscope. Finally,foaf:Namehasrangerdfs:Literal. anonymous class
  54. 54. RDFSEXPRESSIVITY SIMPLE RELATIONSHIP BETWEEN THINGS RDFSprovidesavocabularytoexpressrelationshipbetweenthings (e.g.,subClassOfortype) AVOID COMPLEX RELATIONSHIP RDFScannotdescribedataintermsofsetofoperations(e.g., unionOf), equivalence(e.g.,sameAs)orcardinality(e.g.,allValueFrom)
  55. 55. OWL
  56. 56. WEB ONTOLOGY LANGUAGE WHAT? OWL(version2):aknowledgerepresentationlanguage Designedtoformulate,exchangeandreasonwithknowledgeabouta domainofinterest
  57. 57. WEB ONTOLOGY LANGUAGE INDIVIDUALS,CLASSES AND PROPERTIES “PolitecnicodiTorinoisauniversity” “PolitecnicodiTorinohasaprofessornamedElioPiccolo” “PolitecnicodiTorino”isanobject:anindividualinOWL2 “university”isacategory:aclassinOWL2 “hasaprofessor”isarelation:apropertyinOWL2 “ElioPiccolo”isanindividual,too
  58. 58. WEB ONTOLOGY LANGUAGE EXPRESSIVITY Designedtorepresentrichandcomplexknowledgeaboutthings,group ofthings,andtheirrelations LOGIC-BASED KnowledgeexpressedinOWLcanbereasonedwithacomputerprogram toverifyitsconsistencyortomakeimplicitknowledgeexplicit
  59. 59. WEB ONTOLOGY LANGUAGE LINKED OntologiesinOWLcanbepublishedontheWebandmay refertoorbe referredfromotherOWLontologies CHOOSE THE SYNTAX YOU LIKE VarioussyntaxesavailableforOWL,fordifferentpurposes (RDF/XML,Turtle,Manchester,etc.)
  60. 60. EXAMPLE:BOOKSTORE Intelligenza Artificiale. Un approccio moderno Prentice Hall dc:title dc:publisher Artificial Intelligence: A Modern Approach Prentice Hall dc:title dc:publisher Libro Book rdfs:type rdf:type http://...isbn/9788871925936 http://...isbn/9780136042594
  61. 61. EXAMPLE:BOOKSTORE Intelligenza Artificiale. Un approccio moderno Prentice Hall dc:title dc:publisher Artificial Intelligence: A Modern Approach Prentice Hall dc:title dc:publisher Libro Book rdfs:type rdf:type owl:sameAs http://...isbn/9788871925936 http://...isbn/9780136042594
  62. 62. HANDS ON OWL
  63. 63. EXAMPLE:BOOKSTORE Itistimetosellthebookswemodeled. Usersmusthavethepossibilitytosearchinourbookcatalog. Weneedtodescribeourstore andaddsomeotherinformationaboutthebooks. GoodRelationshelpsinrealizingsuchanexample: http://www.heppnetz.de/projects/goodrelations/
  64. 64. EXAMPLE:BOOKSTORE BUILD THE MODEL 1. Describethebusinessentity 2. Describetheoffereditems 3. Describetheoffer 4. Linktheoffertothebusinessentity SEARCH IN THE MODEL
  65. 65. DESCRIBE THE BUSINESS ENTITY default:BookStore_1 agr:BusinessEntity; gr:legalName“bookstore.comLtd.”^^xsd:string. Bookstore_1
  66. 66. DESCRIBE THE OFFERED ITEMS default:AIBook_en aitem:Book,gr:ActualProductOrServiceInstance ; item:hasTotalPagesdefault:QuantitativeValueInteger_1. AIBook_en default:QuantitativeValueInteger_1 agr:QuantitativeValueInteger; gr:hasValue“1132”^^xsd:integer. QuantitativeValue Integer_1
  67. 67. Bookstore_1 AIBook_en item:BookQuantitativeValue Integer_1 1132 gr:ActualProductOrServiceInstance gr:ProductOrService rdf:type rdfs:subClassOf rdf:type item:hasTotalPages gr:hasValue
  68. 68. DESCRIBE THE OFFER default:Offering_1 agr:Offering ; gr:hasBusinessFunctiongr:Sell; gr:hasPriceSpecificationdefault:UnityPriceSpecification_1; gr:includeObjectdefault:TypeAndQuantityNode_1. Offering_1
  69. 69. Bookstore_1 Offering_1 TypeAndQuantity Node_1UnitPriceSpecification_1 AIBook_en item:BookQuantitativeValue Integer_1 gr:Sell 1.0 1132 gr:ActualProductOrServiceInstance gr:ProductOrService gr:includeObject gr:hasBusinessFunction gr:hasPriceSpecification gr:amountOfThisGood rdf:type rdfs:subClassOf rdf:type item:hasTotalPages gr:hasValue gr:Offering rdf:type
  70. 70. DESCRIBE THE OFFER default:TypeAndQuantityNode_1 agr:TypeAndQuantityNode ; gr:amountOfThisGood“1.0”^^xsd:float; gr:typeOfGooddefault:AIBook_en. default:UnitPriceSpecification_1 agr:UnitPriceSpecification; gr:hasCurrency“EUR”^^xsd:string; gr:hasCurrencyValue “120.0”^^xsd:float. TypeAndQuantity Node_1 UnitPriceSpecification_1
  71. 71. Bookstore_1 Offering_1 TypeAndQuantity Node_1UnitPriceSpecification_1 AIBook_en item:BookQuantitativeValue Integer_1 gr:Sell 120.0 “EUR” 1.0 1132 gr:ActualProductOrServiceInstance gr:ProductOrService gr:includeObject gr:hasBusinessFunction gr:hasPriceSpecification gr:hasCurrency gr:hasCurrencyValue gr:amountOfThisGood gr:typeOfGood rdf:type rdfs:subClassOf rdf:type item:hasTotalPages gr:hasValue gr:Offering rdf:type
  72. 72. default:BookStore_1gr:offersdefault:Offering_1 LINK THE OFFER TO THE BUSINESS ENTITY
  73. 73. Bookstore_1 Offering_1 TypeAndQuantity Node_1UnitPriceSpecification_1 AIBook_en item:BookQuantitativeValue Integer_1 gr:Sell 120.0 “EUR” 1.0 1132 gr:ActualProductOrServiceInstance gr:ProductOrService gr:offers gr:includeObject gr:hasBusinessFunction gr:hasPriceSpecification gr:hasCurrency gr:hasCurrencyValue gr:amountOfThisGood gr:typeOfGood rdf:type rdfs:subClassOf rdf:type item:hasTotalPages gr:hasValue gr:Offering rdf:type
  74. 74. QUERY THE WHOLE! PREFIXgr:<http://purl.org/goodrelations/v1#> PREFIXitem:<http://www.elite.polito.it/ontologies/example/item#> SELECT?offering WHERE{?offeringrdf:typegr:Offering. ?offeringgr:includesObject?object. ?objectgr:typeOfGood?item. ?itemrdf:typeitem:Book. } Howtogetalltheavailableofferforthebook? SPARQL
  75. 75. QUERY THE WHOLE! ?itemrdf:typeitem:Book. SPARQL ?item item:Book rdf:type
  76. 76. QUERY THE WHOLE! ?objectgr:typeOfGood?item. SPARQL ?object AIBook_en item:Book gr:typeOfGood rdf:type
  77. 77. QUERY THE WHOLE! ?offeringgr:includesObject?object. SPARQL ?offering TypeAndQuantity Node_1 AIBook_en item:Book gr:includeObject gr:typeOfGood rdf:type
  78. 78. QUERY THE WHOLE! ?offeringrdf:typegr:Offering. SPARQL ?offering TypeAndQuantity Node_1 AIBook_en item:Book gr:includeObject gr:typeOfGood rdf:type gr:Offering rdf:type
  79. 79. QUERY THE WHOLE! SELECT?offering SPARQL Offering_1 TypeAndQuantity Node_1 AIBook_en item:Book gr:includeObject gr:typeOfGood rdf:type gr:Offering rdf:type
  80. 80. REFERENCES SemanticWebstandards:http://w3c.org/standards/semanticweb SemanticWebWiki:http://semanticweb.org SemanticWebFAQ:http://www.w3c.org/2001/sw/SW-FAQ Book:ASemanticWebPrimer(http://www.semanticwebprimer.org) Book:SemanticWebProgramming(http://semwebprogramming.org) Lastaccess:26May2014
  81. 81. THANKS! LuigiDeRussis http://elite.polito.it
  82. 82. LICENSE ThisworkislicensedundertheCreativeCommons“Attribution-NonCommercial- ShareAlikeUnported(CCBY-NC-SA3,0)”License. Youarefree: toShare-tocopy,distributeandtransmitthework toRemix-toadaptthework Underthefollowingconditions: Attribution -Youmustattributetheworkinthemannerspecifiedbytheauthoror licensor(but notinanywaythatsuggeststhattheyendorseyouoryouruseofthe work). Noncommercial-Youmaynotusethisworkforcommercialpurposes. ShareAlike-Ifyoualter,transform,orbuilduponthiswork,youmaydistributethe resultingworkonlyunderthesameorsimilarlicensetothisone. Toviewacopyofthislicense,visithttp://creativecommons.org/licenses/by-nc-sa/3.0/

×