Upload
intellileaf-ltd
View
909
Download
2
Tags:
Embed Size (px)
DESCRIPTION
Slides from the tutorial given at Nettab 2013 (http://nettab.org/2013)
Citation preview
Semantic Web for Life Sciences
Visions, Aims, Tools, PlatformsAndrea Splendiani
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Index
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
An Introduction to Semantic Web Technologies
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
A new form of Web content that is meaningful to computers will unleash a revolution of new possibilities
Web + Semantics
What
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• RDF: Resource Description Framework
• A language to represent concepts and their relations
• Simple statements:
Subject Predicate Object
• Conceptually a graph
Quick Intro to RDF
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• RDF: Resource Description Framework
• A language to represent concepts and their relations
• Simple statements:
Subject Predicate Object
• Conceptually a graph
Quick Intro to RDF
subjectpredicate
object
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• How does this work in practice ?
• We identify each node and edge by a URI
• (we only need to identify, not define things!)
• URIs could be Web-resolvable
Quick Intro to RDF
subjectpredicate
object
http://nettab.org/biology/Chromosome http://nettab.org/properties/contains http://nettab.org/biology/DNANettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Quick Intro to RDF
http://nettab.org/biology/Chromosome http://nettab.org/properties/contains http://nettab.org/biology/DNA
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Quick Intro to RDF
http://nettab.org/biology/Chromosome http://nettab.org/properties/contains http://nettab.org/biology/DNA
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
RDF:
• No data-types
• No cardinalities
• Importance of identification
http://milicicvuk.com/blog/2011/08/10/fixing-the-rdf-model/
Quick Intro to RDF: RDF vs other modeling
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
The Semantic Web is easy(a bit like html)
Quick Intro to RDF: RDF vs other modeling
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Technology details
• URIs
• The technology stack
• Serializations
• Blank nodes
• Named graphs
• Semantics
• Computational representation of meaning
• RDFS
• OWL
• SKOSNettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• URIs are global identifiers
• Supported by a widely adopted infrastructure (the Web)
• Simple but implicit authority mechanism (namespace)
http://nettab.org/biology/Chromosome
Technology details: URIs
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://www.ncbi.nlm.nih.gov/pubmed/20605693http://dbpedia.org/resource/Berlinhttp://biocyc.org/biopax/biopax#smallMolecule84998http://www.reactome.org/biopax#H2O__ChEBI_15377_http://bio2rdf.org/go:0032283
Technology details: URIs
• Not a consistent “scheme” to define URIs
• Good practices: e.g.: no parameters
• Decision points: semantically opaque or not
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• What is necessary:
• Unambiguous identification
• Persistence (versions)
Technology details: URIs
http://nettab.org/Venice
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
What should URIs resolve to ?
Nothing
http://wifo5-03.informatik.uni-mannheim.de/bizer/pub/LinkedDataTutorial/
Technology details: URIs
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Not a coherent monolithic technology!
Technology details: the technology stack
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://purl.org/go/owl#GO_0006915
http://purl.org/go/owl#GO_0012501
110020
programmed cell death
http://www.w3.org/2000/01/rdf-schema#subClassOf
http://www.w3.org/2000/01/rdf-schema#label
http://www.example.com/hasdbaccession
http://www.example.com/instance1
http://www.w3.org/1999/02/22-rdf-syntax-ns#type
English
Integer
Technology details: serializations
RDF can be represented in many syntaxes
• N-Triples
• Turtle
• XML(s)
• ...
• JSON
• Binary
http://librdf.org/raptor/
Use a tool like Rapper to convert among syntaxes
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://purl.org/go/owl#GO_0006915
http://purl.org/go/owl#GO_0012501
110020
programmed cell death
http://www.w3.org/2000/01/rdf-schema#subClassOf
http://www.w3.org/2000/01/rdf-schema#label
http://www.example.com/hasdbaccession
http://www.example.com/instance1
http://www.w3.org/1999/02/22-rdf-syntax-ns#type
English
Integer
<http://purl.org/obo/owl/GO#GO_0006915> <http://www.w3.org/2000/01/rdf-schema#subClassOf> <http://purl.org/obo/owl/GO#GO_0012501> .
<http://purl.org/obo/owl/GO#GO_0012501> <http://www.w3.org/2000/01/rdf-schema#label> "programmed cell death"@en .
<http://www.example.com/instance1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/obo/owl/GO#GO_0006915> .
<http://www.example.com/instance1> <http://www.example.com/hasdbaccession> "110020"^^<http://www.w3.org/2001/XMLSchema#int> .
Technology details: serializations
N-Triples
• Every subset (lines) is valid N-Triples
• Good for large files, streaming,...
• Very simple to produce via scripts
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://purl.org/go/owl#GO_0006915
http://purl.org/go/owl#GO_0012501
110020
programmed cell death
http://www.w3.org/2000/01/rdf-schema#subClassOf
http://www.w3.org/2000/01/rdf-schema#label
http://www.example.com/hasdbaccession
http://www.example.com/instance1
http://www.w3.org/1999/02/22-rdf-syntax-ns#type
English
Integer
<http://purl.org/obo/owl/GO#GO_0006915> <http://www.w3.org/2000/01/rdf-schema#subClassOf> <http://purl.org/obo/owl/GO#GO_0012501> .
<http://purl.org/obo/owl/GO#GO_0012501> <http://www.w3.org/2000/01/rdf-schema#label> "programmed cell death"@en .
<http://www.example.com/instance1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/obo/owl/GO#GO_0006915> .
<http://www.example.com/instance1> <http://www.example.com/hasdbaccession> "110020"^^<http://www.w3.org/2001/XMLSchema#int> .
Technology details: serializations
N-Triples
• Every subset (lines) is valid N-Triples
• Good for large files, streaming,...
• Very simple to produce via scripts
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://purl.org/go/owl#GO_0006915
http://purl.org/go/owl#GO_0012501
110020
programmed cell death
http://www.w3.org/2000/01/rdf-schema#subClassOf
http://www.w3.org/2000/01/rdf-schema#label
http://www.example.com/hasdbaccession
http://www.example.com/instance1
http://www.w3.org/1999/02/22-rdf-syntax-ns#type
English
Integer
<http://purl.org/obo/owl/GO#GO_0006915> <http://www.w3.org/2000/01/rdf-schema#subClassOf> <http://purl.org/obo/owl/GO#GO_0012501> .
<http://purl.org/obo/owl/GO#GO_0012501> <http://www.w3.org/2000/01/rdf-schema#label> "programmed cell death"@en .
<http://www.example.com/instance1> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/obo/owl/GO#GO_0006915> .
<http://www.example.com/instance1> <http://www.example.com/hasdbaccession> "110020"^^<http://www.w3.org/2001/XMLSchema#int> .
Technology details: serializations
N-Triples
• Every subset (lines) is valid N-Triples
• Good for large files, streaming,...
• Very simple to produce via scripts
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://purl.org/go/owl#GO_0006915
http://purl.org/go/owl#GO_0012501
110020
programmed cell death
http://www.w3.org/2000/01/rdf-schema#subClassOf
http://www.w3.org/2000/01/rdf-schema#label
http://www.example.com/hasdbaccession
http://www.example.com/instance1
http://www.w3.org/1999/02/22-rdf-syntax-ns#type
English
Integer
Technology details: serializations
Turtle
• Easy to read
• Easy to write by hand (keyboard)
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .@prefix GO: <http://purl.org/obo/owl/GO#> .@prefix : <http://www.example.com/> .
go:GO_0006915 rdfs:subClassOf go:GO_0012501 .
go:GO_0012501> rdfs:label "programmed cell death"@en .
:instance1 :hasdbaccession "110020"^^<http://www.w3.org/2001/XMLSchema#int> ; a go:GO_0006915 .
http://prefix.cc/
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Technology details: serializations
RDFXML<?xml version="1.0" encoding="utf-8"?><rdf:RDF xmlns:go="http://purl.org/obo/owl/GO#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns="http://www.example.com/"> <rdf:Description rdf:about="http://purl.org/obo/owl/GO#GO_0006915"> <rdfs:subClassOf rdf:resource="http://purl.org/obo/owl/GO#GO_0012501"/> </rdf:Description> <rdf:Description rdf:about="http://purl.org/obo/owl/GO#GO_0012501"> <rdfs:label xml:lang="en">programmed cell death</rdfs:label> </rdf:Description> <rdf:Description rdf:about="http://www.example.com/instance1"> <rdf:type rdf:resource="http://purl.org/obo/owl/GO#GO_0006915"/> </rdf:Description> <rdf:Description rdf:about="http://www.example.com/instance1"> <hasdbaccession rdf:datatype="http://www.w3.org/2001/XMLSchema#int">110020</hasdbaccession> </rdf:Description></rdf:RDF>
Good for ?
<go:GO_0006915 rdf:about="http://www.example.com/instance1"> <hasdbaccession rdf:datatype="http://www.w3.org/2001/XMLSchema#int">110020 </hasdbaccession> </go:GO_0006915>
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
<http://dbpedia.org/resource/Venice> foaf:based_near [ geo:lat "45.4375" ; geo:long "12.335833" ; a <http://example/Point> ] .
<http://dbpedia.org/resource/Venice> foaf:based_near _:p1 ._:p1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://example/Point> ._:p1 <http://www.w3.org/2003/01/geo/wgs84_pos#:lat> "45.4375" ._:p1 <http://www.w3.org/2003/01/geo/wgs84_pos#:long> "12.335833" .
<rdf:Description rdf:about="http://dbpedia.org/resource/Venice"> <foaf:based_near> <geo:Point> <geo:lat>45.4375</geo:lat> <geo:long>12.335833</geo:long> </geo:Point> </foaf:based_near> </rdf:Description>
Technology details: blank nodes
• Some entities may not have a global identifier
• Could we always provide one ?
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
<http://dbpedia.org/resource/Venice> foaf:based_near _:p1 nettabex:1._:p1 rdf:type <http://example/Point> nettabex:1._:p1 geo:lat "45.4375" nettabex:1._:p1 geo:long "12.335833" nettabex:1.
Technology details: named graphs
• An entire (sub)graph can be identified (“named”) by a URI
• Graphs can be subject and object of predicates
• Good to represent context (hence provenance...)
(pseudo N-quads)Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
https://www.usenix.org/legacy/event/tapp09/tech/full_papers/pediaditis/pediaditis_html/
Technology details: semantics
Facts Defining reality Computing definitions
Ontology:“A formalization of a conceptualization”
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://www.ifomis.org/bfo
Ontologies:The conceptualization
Technology details: semantics
extract from BFO
extract from RONettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
GO:GO_0006915
GO:GO_0012501apoptosis
programmed cell death
rdfs:subClassOf
rdfs:label
rdfs:label
GO:GO_0008585
rdfs:subClassOf
virus-infected cell
apoptosis
rdfs:label
GO:GO_0006915
GO:GO_0012501apoptosis
programmed cell death
rdfs:subClassOf
rdfs:label
rdfs:label
GO:GO_0008585
rdfs:subClassOf
virus-infected cell
apoptosis
rdfs:label
(?x rdfs:subClassOf ?y)(?y rdfs:subClassOf ?z) -> (?x rdfs:subClassOf ?z)
Technology details: representation of meaning
Computational representation of meaning: transitive property
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• Inconsistency• Classification• Consistency• Subsumption
Technology details: representation of meaning
Some possible computations
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• Emergent Semantics• First order logic• Inference rules• RDFS• OWL (-2, DL, RL, QL...)• SKOS
Technology details: representation of meaning
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
RDF-S: • type • subClassOf• subPropertyOf• ...
GO:GO_0006915
GO:GO_0012501apoptosis
programmed cell death
rdfs:subClassOf
rdfs:label
rdfs:label
GO:GO_0008585
rdfs:subClassOf
virus-infected cell
apoptosis
rdfs:label
Inconsistence ?
Technology details: RDFS
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
OWL: • Class Union/Intersection• Universal/Existential restriction• Property Domain/Range• Transitive/Reflexive/Functional properties• ...
• OWL provides a set of properties and resources to characterize classes.
• OWL supports inference of the class structure of an ontology
• OWL has several variants addressing different trade-offs in computability/expressivity
• Many ontologies “use OWL”, but they really only use a few axioms (almost like RDFS)
• OWL is not a schema language! (Classes and properties have a different meaning than OO)
Inconsistence !
Technology details: OWL
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Example: cell motility part of localization of cell
<owl:Class rdf:about="GO#GO_0006928"> <rdfs:label xml:lang="en">cell motility</rdfs:label> <rdfs:subClassOf> <owl:Restriction> <owl:onProperty rdf:resource="obo#part_of"/> <owl:someValuesFrom rdf:resource="GO#GO_0051674"/> </owl:Restriction> </rdfs:subClassOf>...</owl:Class>
Technology details: OWL
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
OWL Inference is not validation!
Person hasFather exactly 1
George a PersonGeorge hasFather MarkGeorge hasFather John
John sameAs Mark
•RDF Validation: Syntax•(OWL) Reasoning: Consistency•SPIN Rules (later)
Technology details: OWL
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Two things to possibly avoid when working with OWL/RDF:
• use RDF/XML
• use OO tools
Technology details: OWL
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Technology details: SKOS
• SKOS: Simple Knowledge Organization System
• Not a formal system (can be mapped to OWL)
• Weak semantic connotation, but useful in many classification tasks
You don’t improve the ontological commitment of a classification system by representing it in OWL (if the conceptualization doesn’t improve!)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Why Life Sciences ?
Why Semantic Web ?Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Why ? Heterogeneous information
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• The DNA model has around 60 years (’53)
• “basic principles” changed in a timescale of about 10 years
The textbook tale
Missing: epigenetics, miRNA
Why ? Mutability of information (schema)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
The meaning of “Gene”
Why ? Complex Semantics
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Why ? The Semantic Web can Help How ?
• Makes data integration easier
• Makes semantic problems explicit
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Why ? The Semantic Web can Help How ?
• Makes data integration easier
• Makes semantic problems explicit
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Easy data integration: what if we used a relational model
CityID population CityName
INT INT VARHCHAR(45)
1 40885 Venezia
UniversityID students established CityID CityName
INT INT Date INT TEXT
1 20000 1868 2 Venice
Why ? The Semantic Web can Help How ?
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
CityID population CityName
INT INT VARHCHAR(45)
1 40885 Venezia
UniversityID students established CityID CityName
INT INT Date INT TEXT
1 20000 1868 2 Venice
Why ? The Semantic Web can Help How ?
Easy data integration: what if we used a relational model
Implicit foreign key
In the Semantic Web “keys” are explicit by definitionNettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
CityID population CityName
INT INT VARHCHAR(45)
1 40885 Venezia
UniversityID students established CityID CityName
INT INT Date INT TEXT
1 20000 1868 2 Venice
Why ? The Semantic Web can Help How ?
Easy data integration: what if we used a relational model
Local identifiers, mappings required
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
CityID population CityName
INT INT VARHCHAR(45)
1 40885 Venezia
UniversityID students established CityID CityName
INT INT Date INT TEXT
1 20000 1868 2 Venice
Why ? The Semantic Web can Help How ?
Easy data integration: what if we used a relational model
What is the type of a CityName ?How many names can a city have ? Is the city name a key ?
Perhaps we can assume that in the same country, two cities with the same name are the same city.We could just declare rdfs:property as functional to deduce such equivalences.
Does the University of Venice only exists in Venice ? Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
The broader view
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
The broader view
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• All predicates are global (no implicit contexts)
• Declarative vs imperative processing of information
• Immutability: once information is out, you cannot control it
• Monotonicity: you only add information
• There may be more that what you know: Open World Assumption
The broader view: Not only NoSQL
The Semantic Web is not only a technology to handle data. Being “Semantic” and “Web” has some implication on the way information is thought
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
HOWTO publish information on the Semantic Web
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
HOWTO publish information on the Semantic Web
Simply link an RDF filePossibly via a good URI
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
HOWTO publish information on the Semantic Web
Programmatic access via a SPARQL endpoint(can be resource intensive)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
<div xmlns:dc="http://purl.org/dc/elements/1.1/"> <div about="/alice/posts/trouble_with_bob"> <h2 property="dc:title">The trouble with Bob</h2> <h3 property="dc:creator">Alice</h3> ... </div>
<div about="/alice/posts/jos_barbecue"> <h2 property="dc:title">Jo's Barbecue</h2> <h3 property="dc:creator">Eve</h3> ... </div>
</div>
HOWTO publish information on the Semantic Web
Embed RDF in html (e.g.: RDFa)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Linked Data APIs (ELDA), Linked Data Platform, Linked Data JSON ...
http://www4.wiwiss.fu-berlin.de/bizer/pub/LinkedDataTutorial/
HOWTO publish information on the Semantic Web
Publish information as Linked-Data
• Linked Data is a set of good practices to publish RDF
• Use only HTTP resolvable URIs
• Dereferencing URIs (202 information resources 303 see other)
• Content negotiation
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
LAT pp Grb2LAT pp PI3K_p85-alphaLAT pp PLC-gammaLAT pp GrapLAT pp GadsSLP-76 pp VavSLP-76 pp NckSLP-76 pp SLAP-130SLP-76 pp GadsSLP-76 pp ShcSLP-76 pp CblSLP-76 pp LynSLP-76 pp PLC-gamma2CD28 pp Grb2CD28 pp PI3K_p85-betaCD28 pp CD80
CityID population CityName
INT INT VARHCHAR(45)
1 40885 Venice
Table SIFhttp://ns/ID#1 http://ns/prop#population 40885http://ns/ID#1 http://ns/prop#CityName Venice
<http://ns/ID#$1 http://ns/prop#$2 http://ns/ID#$3>
HOWTO: simple conversions to RDF
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://d2rq.org
http://www.w3.org/TR/2012/PR-rdb-direct-mapping-20120814/http://www.w3.org/TR/2012/REC-r2rml-20120927/
HOWTO: relational to RDF mapping
D2RQ
• Relational to RDF conversion
• Dynamic rendering (SPARQL)
• Linked data frontend (Pubby)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Automated mapping:
D2RQ (like other tools) by default only generates a structural mapping (this can then be tuned).It cannot generate a dc:creator property between Paper and Author
HOWTO: relational to RDF mapping
ID (key)
Name
AuthorID (fkey)
PaperID (fkey)
...
ID (key)
PubmedID
Title
Author Paper
Author2Paper
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
# Table Authormap:author a d2rq:ClassMap; d2rq:dataStorage map:database; d2rq:uriPattern "author/@@Author.ID@@"; d2rq:class foaf:person; d2rq:classDefinitionLabel "author"; .map:author_name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:author; d2rq:property foaf:name; d2rq:propertyDefinitionLabel "Author_name"; d2rq:column "Author.Name"; .
HOWTO: relational to RDF mapping
Example edited mapping:
ID (key)
Name
AuthorID (fkey)
PaperID (fkey)
...
ID (key)
PubmedID
Title
Author Paper
Author2Paper
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
map:hasAuthor a d2rq:PropertyBridge; d2rq:belongsToClassMap map:Paper; d2rq:property :hasAuthorEmail; d2rq:column "Author.Email"; d2rq:join "Paper.ID <= Author2Paper.PaperID"; d2rq:join "Author2Paper.PersonID => Person.ID"; d2rq:datatype xsd:string; d2rq:propertyDefinitionLabel "email"@en; d2rq:propertyDefinitionComment "Author email"@en; .
HOWTO: relational to RDF mapping
ID (key)
Name
AuthorID (fkey)
PaperID (fkey)
...
ID (key)
PubmedID
Title
Author Paper
Author2Paper
map:Paper a d2rq:ClassMap; d2rq:class :Paper; d2rq:uriPattern "http://togows.dbcls.jp/entry/pubmed/@@Paper.PubmedID@@.ttl d2rq:condition "Papers.PubmedID != \”\”"; d2rq:dataStorage map:Database1.
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Discussion + Jena
http://www.apache.org/dist/jena/binaries/
HOWTO setup your own triplestore
Just run: fuseki --loc=path --update /Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://protege.stanford.edu
Ontologies and Protege
Practical suggestions:
• Produce RDF (simple scripts or mapper)
• Translate among syntaxes via Rapper
• Build ontologies (for your RDF) in Protege
Ontology editor
mercoledì 16 ottobre 13
Protege to edit and visualize the ontology. Rely on the triplestore for inference.
Ontologies and Protege
Two typical scenarios of interoperability between RDF and Ontologies
Ontologies are large taxonomies or DAGs, only transitive inference is used.(E.g.: SKOS-like)
Ontologies are complex terminology that rely on axioms for consistency and inference
Edit in Protege, classify the ontology via reasoner, then use the results in combination with other RDF statements.
Third scenario....Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Ontologies and Protege
You can specify URIs as to match your RDF
mercoledì 16 ottobre 13
Ontologies and Protege
• Relations are first class objects
• Specifying domain, range and annotation can go a long way in
• “documenting” the ontology
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
rdf.myexperiment.org/void.rdfhttp://www.w3.org/TR/void/
VOID and metadata
VOID: Metadata about a dataset.
• Provenance• License• Vocabularies• Statistics
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
curl -H "Accept: application/rdf+xml" http://beta.sparql.uniprot.org/sparql
VOID and metadata
SPARQL service descriptor
• Query language supported
• Formats returned• Entailment regime• ...
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
VOID and metadata
Consider registering your data in a data registerNettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
HOWTO use information from the Semantic Web
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
# NAME : Get psoriasis proteins# PARAMETER: psoriasis: the disease name# FUNCTION : returns all the proteins that have 'psoriasis' in# their Swiss-Prot disease description and their# interacting proteins (if known)
BASE <http://www.semantic-systems-biology.org/>PREFIX rdfs:<http://www.w3.org/2000/01/rdf-schema#>PREFIX ssb:<http://www.semantic-systems-biology.org/SSB#>SELECT distinct ?protein_name ?disease_description ?interacts_with ?encoded_byWHERE { GRAPH <uniprot_sprot> { ?protein_id ssb:disease ?disease_description. ?protein_id ssb:mnemonic ?protein_name. OPTIONAL { ?protein_id ssb:interacts_with ?interactor. ?interactor ssb:mnemonic ?interacts_with. ?interactor ssb:encoded_by ?encoded_by. } } FILTER regex(?disease_description, 'psoriasis').}
http://www.semantic-systems-biology.org/biogateway/endpoint?default-graph-uri=&query=%23+NAME+++++%3A+Get+psoriasis+proteins%0D%0A%23+PARAMETER%3A+psoriasis%3A+the+disease+name%0D%0A%23+FUNCTION+%3A+returns+all+the+proteins+that+have+%27psoriasis%27+in%0D%0A%23++++++++++++their+Swiss-Prot+disease+description+and+their%0D%0A%23++++++++++++interacting+proteins+%28if+known%29%0D%0A%0D%0ABASE+++%3Chttp%3A%2F%2Fwww.semantic-systems-biology.org%2F%3E%0D%0APREFIX+rdfs%3A%3Chttp%3A%2F%2Fwww.w3.org%2F2000%2F01%2Frdf-schema%23%3E%0D%0APREFIX+ssb%3A%3Chttp%3A%2F%2Fwww.semantic-systems-biology.org%2FSSB%23%3E%0D%0ASELECT+distinct+%3Fprotein_name+%3Fdisease_description%0D%0A+++++++%3Finteracts_with+%3Fencoded_by%0D%0AWHERE+%7B%0D%0A++GRAPH+%3Cuniprot_sprot%3E+%7B%0D%0A++++%3Fprotein_id+ssb%3Adisease+%3Fdisease_description.%0D%0A++++%3Fprotein_id+ssb%3Amnemonic+%3Fprotein_name.%0D%0A++++OPTIONAL+%7B%0D%0A++++++%3Fprotein_id+ssb%3Ainteracts_with+%3Finteractor.%0D%0A++++++%3Finteractor+ssb%3Amnemonic+%3Finteracts_with.%0D%0A++++++%3Finteractor+ssb%3Aencoded_by+%3Fencoded_by.%0D%0A++++%7D%0D%0A++%7D%0D%0A++FILTER+regex%28%3Fdisease_description%2C+%27psoriasis%27%29.%0D%0A%7D&format=text%2Fhtml&debug=on
Introduction to SPARQL
SPARQL is REST! (one query is one URL)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
SELECT ?x ?y...WHERE {GRAPH PATTERN}
CONSTRUCT {?x ?y ?z}WHERE {GRAPH PATTERN}
ASKDESCRIBE
Introduction to SPARQL
SPARQL supports different kind of queries
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Introduction to SPARQL
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>PREFIX owl: <http://www.w3.org/2002/07/owl#>PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>PREFIX dc: <http://purl.org/dc/elements/1.1/>PREFIX dcterms: <http://purl.org/dc/terms/>PREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX skos: <http://www.w3.org/2004/02/skos/core#>PREFIX biopax3: <http://www.biopax.org/release/biopax-level3.owl#>
SELECT DISTINCT ?pathway ?pathwayname WHERE {?pathway rdf:type biopax3:Pathway . ?pathway biopax3:displayName ?pathwayname .?pathway biopax3:pathwayComponent ?reaction . ?reaction rdf:type biopax3:BiochemicalReaction . ?reaction ?rel ?protein .?protein rdf:type biopax3:Protein . ?protein biopax3:entityReference <http://purl.uniprot.org/uniprot/P01308> } LIMIT 100
<http://identifiers.org/reactome/REACT_15550.4> Insulin Processing<http://identifiers.org/reactome/REACT_18325.4> Regulation of Insulin Secretion
Introduction to SPARQL
Graph patterns
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Introduction to SPARQL
Graph patterns
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Introduction to SPARQL
How do I know what to query ?
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>PREFIX owl: <http://www.w3.org/2002/07/owl#>PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>PREFIX dc: <http://purl.org/dc/elements/1.1/>PREFIX dcterms: <http://purl.org/dc/terms/>PREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX skos: <http://www.w3.org/2004/02/skos/core#>PREFIX biopax3: <http://www.biopax.org/release/biopax-level3.owl#>
SELECT DISTINCT ?pathway ?pathwayname WHERE {?pathway rdf:type biopax3:Pathway . ?pathway biopax3:displayName ?pathwayname .FILTER regex(?pathwayname, "Insulin", "i")} LIMIT 100
Introduction to SPARQL
Filters
More operators!
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
SELECT DISTINCT ?pathway ?pathwayname WHERE {?pathway rdf:type biopax3:Pathway . ?pathway biopax3:displayName ?pathwayname .?pathway biopax3:pathwayComponent ?reaction . ?reaction rdf:type biopax3:BiochemicalReaction . { {?reaction ?rel ?protein .} UNION { ?reaction ?rel ?complex . ?complex rdf:type biopax3:Complex . ?complex ?comp ?protein . }} ?protein rdf:type biopax3:Protein . ?protein biopax3:entityReference <http://purl.uniprot.org/uniprot/P01308> } LIMIT 100
Introduction to SPARQL
Combining graph matching: union and diff
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Introduction to SPARQL
SELECT DISTINCT ?pathway ?pathwayname WHERE {?pathway rdf:type biopax3:Pathway . ?pathway biopax3:displayName ?pathwayname .?pathway biopax3:pathwayComponent ?reaction . ?reaction rdf:type biopax3:BiochemicalReaction . { {?reaction ?rel ?protein .} UNION { ?reaction ?rel ?complex . ?complex rdf:type biopax3:Complex . ?complex ?comp ?protein . }} ?protein rdf:type biopax3:Protein . ?protein biopax3:entityReference <http://purl.uniprot.org/uniprot/P01308> } LIMIT 100
Aggregators
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
<http://www.openlinksw.com/schemas/virtrdf#><http://rdf.ebi.ac.uk/dataset/reactome/45><http://rdf.ebi.ac.uk/dataset/reactome/description>
Introduction to SPARQL
Named graphs
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
select distinct ?g where { graph ?g {?s ?p ?o}}
<http://www.openlinksw.com/schemas/virtrdf#><http://rdf.ebi.ac.uk/dataset/reactome/45><http://rdf.ebi.ac.uk/dataset/reactome/description>
select distinct ?o where { graph <http://rdf.ebi.ac.uk/dataset/reactome/45> {?s a ?o}}
2221044
select count (distinct ?s) where { graph <http://rdf.ebi.ac.uk/dataset/reactome/45> {?s ?p ?o}}
owl:Ontologybiopax3:FragmentFeaturebiopax3:SmallMoleculeReferencebiopax3:TemplateReactionbiopax3:Controlbiopax3:EvidenceCodeVocabularybiopax3:SequenceSitebiopax3:Stoichiometrybiopax3:Catalysisbiopax3:PathwayStepbiopax3:UnificationXrefbiopax3:Proteinbiopax3:PublicationXrefbiopax3:PhysicalEntitybiopax3:CellularLocationVocabularybiopax3:Complexbiopax3:BiochemicalReaction...
select count (distinct ?s) where { ?s ?p ?o} 2221353
Introduction to SPARQLHow do I know what to query ?A “practical example”...
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>PREFIX owl: <http://www.w3.org/2002/07/owl#>PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>PREFIX dc: <http://purl.org/dc/elements/1.1/>PREFIX dcterms: <http://purl.org/dc/terms/>PREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX skos: <http://www.w3.org/2004/02/skos/core#>PREFIX biopax3: <http://www.biopax.org/release/biopax-level3.owl#>
SELECT DISTINCT ?pathway ?pathwayname WHERE {SERVICE<http://beta.sparql.uniprot.org/sparql> {?uniprotID <http://purl.uniprot.org/core/encodedBy> ?o .?o <http://www.w3.org/2004/02/skos/core#prefLabel> "INS"} ?pathway rdf:type biopax3:Pathway . ?pathway biopax3:displayName ?pathwayname .?pathway biopax3:pathwayComponent ?reaction . ?reaction rdf:type biopax3:BiochemicalReaction . ?protein rdf:type biopax3:Protein . ?protein biopax3:entityReference ?uniprotID } LIMIT 100
SPARQL: advanced features
Distributed queries
Don’t change the order!Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://www.w3.org/TR/sparql11-update/
PREFIX dc: <http://purl.org/dc/elements/1.1/>INSERT DATA{ <http://example/book1> dc:title "A new book" ; dc:creator "A.N.Other" .}
PREFIX dc: <http://purl.org/dc/elements/1.1/>INSERT DATA { GRAPH <http://example/graph>{ <http://example/book1> dc:title "A new book" ; dc:creator "A.N.Other" .} }
PREFIX dc: <http://purl.org/dc/elements/1.1/>PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
INSERT { GRAPH <http://example/bookStore2> { ?book ?p ?v } }WHERE { GRAPH <http://example/bookStore> { ?book dc:date ?date . FILTER ( ?date > "1970-01-01"^^xsd:dateTime ) ?book ?p ?v } }
PREFIX foaf: <http://xmlns.com/foaf/0.1/>DELETE WHERE { ?person foaf:givenName 'Fred'; ?property ?value }
SPARQL: advanced features
SPARQL update
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://spinrdf.org/
SPARQL: advanced features
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Reasoners
• Different varieties: simple transitive reasoning can be embedded in triplestores
• Rule based
• OWL-reasoners (OWL, Fact++): can be stand-alone or embedded in other applications (e.g.: Protege)
http://www.w3.org/2001/sw/wiki/OWL/Implementations
Example of Tools
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://semweb.salzburgresearch.at/apps/rdf-gravity/user_doc.html
Example of Tools
RDF visualization tools (graph based)
Think about reification! (not always intuitive)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Example of Tools
OWL visualization tools (class based)
http://protegewiki.stanford.edu/index.php/OWLViz
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://www.visualdataweb.org/relfinder.php
Example of Tools
Information discovery
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Example of ToolsIntegrated environments: mapping, visualization, editing, analysis, exploration
http://io-informatics.com
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Example of Tools
Facet browsers
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
https://code.google.com/p/sgvizler/
<div id="sgvzl_example1" data-sgvizler-endpoint="http://sws.ifi.uio.no/sparql/npd" data-sgvizler-query="SELECT ?class (count(?instance) AS ?noOfInstances) WHERE{ ?instance a ?class } GROUP BY ?class ORDER BY ?class" data-sgvizler-chart="gPieChart" style="width:800px; height:400px;"></div>
Example of Tools
Visualization/mashup libraries
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://biordf.net/cardioSHARE/
Example of Tools
Infrastructures
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
The Semantic Web Landscape
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://www.uniprot.org
RDF available via:•Content negotiation•Extension•Endpoint
Lot of triples!
http://www.ebi.ac.uk/rdf/documentation/uniprot/
Primary Resources
Uniprot
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Primary Resources
EBI RDF Platform
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Primary Resources
EBI: indentifiers.org
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://data.nature.com
Pubmed: http://togows.dbcls.jp
Primary Resources
“Some” literature
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://beta.geneontology.org/page/download-ontology
Primary Resources
Gene Ontology
getting OWL!Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://sparql.wikipathways.org
Primary Resources
Wikipathways (OpenPhacts)
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
freebase...
Primary Resources
DBPedia
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://bioportal.bioontology.org/
Integrated Resources
BioPortal
• Ontologies, mappings and tools• Most of ontologies are large
terminology collections
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
To be filled
Integrated Resources
BioPortal: detail on SPARQL queries and ontology representation
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
BioPortal: detail on SPARQL queries and ontology representation
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
Bio2RDF
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://linkedlifedata.com
Integrated Resources
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
DistilBio
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
PathwayCommons integrates pathway information via BioPAX
GO: 39k termsNettab, 16th October 2013, Venice Andrea Splendiani @AndSplend
andrea.splendiani@[deri.org,intellileaf.com]Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Integrated Resources
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
http://lod-cloud.net/versions/2011-09-19/lod-cloud_colored.html
LOD: Linked Open Data
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
LOD: Linked Open Data
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
LOD: Linked Open Data
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
LOD: Linked Open Data
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
LOD: Linked Open Data
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Is the Semantic Web good for you ?
• Are resources reliable ? (a business problem)
• Does it solve the Semantic Integration problem ? (No)
• How can I know which resources to use ? (Not easy)
• Is the technology mature ? Part of it.
Conclusions
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
• Beyond Syntax
• Explicit Semantics
• Web technologies (SPARQL as REST, distributed queries)
• Several interesting resources
• Some technologies are robust (RDF, SPARQL, ...)
Conclusions
Is the Semantic Web good for you ?
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13
Exercise
• Get Jena Fuseki
• Start the server
• Add some triples via the web interface
• Make a distributed query to Uniprot
<http://myHomePage> <http://nettab.org/example/chosenProtein> <uniprotID>
Nettab, 16th October 2013, Venice Andrea Splendiani @AndSplendandrea.splendiani@[deri.org,intellileaf.com]
Semantic Web for Life Sciences: Visions, Aims, Tools, Platforms
mercoledì 16 ottobre 13