#sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

44
Pubblicare LOD ////////////////////////////// lo stato in Italia /////////////////////////////// un’analisi dei requisiti tecnologici ////////// a spasso per il web dei dati ///////////////// SPAGHETTI OPEN DATA DIEGO VALERIO CAMARDA / REGESTA.EXE / LODLIVE bologna, 28th—30th march 2014

description

Pubblicare LOD lo stato in Italia un’analisi dei requisiti tecnologici a spasso per il web dei dati

Transcript of #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

Page 1: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

Pubblicare LOD //////////////////////////////lo stato in Italia ///////////////////////////////un’analisi dei requisiti tecnologici //////////a spasso per il web dei dati /////////////////

SPAGHETTI OPEN DATA

DIEGO VALERIO CAMARDA / REGESTA.EXE / LODLIVE

bologna, 28th—30th march 2014

Page 2: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

dvcama

@dvcama

[email protected]

This presentation is based on data generated using https://github.com/dvcama/lod-tester

The tool has been written expressly for the LOD2014 conference and has been published in open source to verify and allow further analysis

Page 3: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

STATE OF THE ART

Page 4: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

analyzing

STATE OF THE ART

Page 5: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

2012, November

Page 6: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico
Page 7: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico
Page 8: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

2014, March

Page 9: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

in figures

STATE OF THE ART

Page 10: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

triples entities bn classes properties

Archivio Centrale dello Stato 13 505 291 1 364 274 307 806 55 232

Camera dei deputati 46 358 811 3 950 999 295 989 68 245

CNR 8 862 396 485 977 365 120 207

Comune di Firenze 63 389 8 422 – 4 22

CulturaItalia 30 388 021 4 914 280 3 192 174 104 249

DBpedia Italia 94 165 863 2 643 141 6 145 12 558

LinkedStat 136 407 747 10 595 346 4 421 481 971

Progetto Reload 17 493 969 818 194 935 048 45 234

Provincia Carbonia Iglesias 208 228 62 952 – 13 17

Ragioneria Generale dello Stato 4 909 143 227 256 – 32 437

Senato della Repubblica 29 676 869 1 074 927 300 013 50 225

SPCdata 1 787 158 291125 70 79 220

Page 11: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

triples /entities

Archivio Centrale dello Stato 10

Camera dei deputati 10

CNR 18

Comune di Firenze 8

CulturaItalia 4

DBpedia Italia 79

LinkedStat 13

Progetto Reload 21

Provincia Carbonia Iglesias 3

Ragioneria Generale dello Stato 22

Senato della Repubblica 22

SPCdata 6

bn /entities

0.25

0.03

0.00

0.00

0.39

0.00

0.00

1.14

0.00

0.00

0.22

0.00

prop /classes

4.46

3.40

1.73

5.50

2.39

36.49

2.02

5.20

1.31

13.63

4.50

3.93

Page 12: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

triples

entitiesproperties

classes bn

Archivio Centrale dello Stato

Camera dei deputati

CNR

Comune di Firenze

CulturaItalia

DBpedia Italia

LinkedStat

Progetto Reload

Provincia Carbonia Iglesias

Ragioneria Generale dello Stato

Senato della Repubblica

SPCdata

Page 13: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

italian linked data cloud

STATE OF THE ART

Page 14: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

LinkedStat➤0

ArchivioCentrale

dello Stato➤0

DBpediaItalia➤328

780

293

4

30

11

3 001

587

895

7 096

1 375

6 582

41

41

2

1

7 096507

7 73

1

1

Cameradei deputati➤4 483

SPCdata➤2

ProgettoReload➤0

CNR➤3

CulturaItalia➤0

DBpedia➤16 650

LinkedGeoData➤14 699

Senato della

Repubblica➤0

RagioneriaGenerale

dello Stato➤0

Comune di Firenze

➤0

ProvinciaCarboniaIglesias➤0

Page 15: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

PUT YOURLOD ONLINE

Page 16: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

focusing on goals

PUT YOURLOD ONLINE

Page 17: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

WEB

VS. VS.

VS. DATA

WEB OF DATA

Page 18: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

the goals:

› build a new web, different but complementary to the classic web

› allow machine exploration through standard technologies

› guarantee reliability as in the classic web

› accept that publishing LOD is not a goal, it’s just a starting point

› use owl:sameAs (and similar) as the new Hypertext Links

Page 19: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

for machines, not for humans

PUT YOURLOD ONLINE

Page 20: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

machine experience issues: 84% mastered

› the endpoint supports SPARQL content negotiation 11/11

› the endpoint (triplestore) is up-to-date 9/11

› the endpoint uses port 80 (HTTP) 9/11

› the endpoint supports JSONP calls 9/11

› the endpoint URL is easy to deduce from resources 8/11

› the resources are on-line 10/11

› the URIs support rdf+xml via content negotiation 9/11

› the resources are described by dc:title or rdfs:label 9/11

Page 21: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

ok, humans also are important

PUT YOURLOD ONLINE

Page 22: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

user experience issues: 79% mastered

› the endpoint hosts a page for humans 8/11

› the resources and the endpoint are on the same domain 9/11

› the URIs support text/html via content negotiation 9/11

Page 23: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

and the winner is…

PUT YOURLOD ONLINE

Page 24: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

11 endpoints 22 544 920 entities283 841 970 facts

And the best endpoints are…

Italian Linked Data Cloud

Page 25: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

11 endpoints 22 544 920 entities283 841 970 facts

And the best endpoints are…

Italian Linked Data Cloud

The bests endpointsCLASSIFIED

Page 26: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

TIME FOR ACTION

Page 27: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

exploring interoperability

TIME FOR ACTION

Page 28: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

lodlive.it github.com/dvcama/LodLive

Page 29: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

Ok, è un endpoint SPARQL... non facciamoci

prendere dal panico.

Page 30: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

cosa abbiamo sotto mano?

select distinct ?o where {?s a ?o}

01/10

Page 31: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

ma in effetti di che si tratta?

select ?o count(distinct ?s) where {?s a ?o}

02/10

Page 32: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

quanti fatti abbiamo a disposizione?

select count(?s) where {?s ?p ?o}

03/10

Page 33: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

quali sono le entità più descritte?

select count(?s) ?class where {?s ?p ?o; a ?class}

04/10

Page 34: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

scegliamo una classe e vediamo come è descritta

select distinct ?p where {?s a <http://classe>; ?p ?o}

05/10

Page 35: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

tutte le sue proprietà sono ugualmente importanti?

select ?p count(?p) where {?s a <http://classe>; ?p ?o}

06/10

Page 36: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

per una data classe elenchiamo un po’ di URI

select ?s where {?s a <http://classe>}

LIMIT 100

07/10

Page 38: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

ops, c’è un blank node!

select distinct ?p ?o ?p1 ?o2 where {<http://URI> ?p ?o.

OPTIONAL{?o ?p1 ?o2. FILTER(isBlank(?o))}}

09/10

Page 39: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

aggiungiamo un po’ di carne al fuoco (non troppa)

select distinct ?s ?title where {?s a <http://classe>;

dc:title ?title. FILTER(REGEX(?title,’parola’,’i’))} LIMIT 100

10/10

Page 40: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

REFERENCES

Page 41: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

italian endpoints adresses

REFERENCES

Page 42: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

Archivio Centrale dello Stato http://dati.acs.beniculturali.it/sparql

Camera dei deputati http://dati.camera.it/sparql

CNR http://data.cnr.it/sparql-proxy

Comune di Firenze http://linkeddata.comune.fi.it:8080/sparql

CulturaItalia http://dati.culturaitalia.it/sparql

DBpedia Italia http://it.dbpedia.org/sparql

LinkedStat http://linkedstat.spaziodati.eu

Progetto Reload http://lod.xdams.org/sparql

Provincia Carbonia Iglesias http://www.provincia.carboniaiglesias.it/sparql

Ragioneria Generale dello Stato http://dwrgsweb-lb.rgs.mef.gov.it/DWRGSXL/sparql

Senato della Repubblica http://dati.senato.it/sparql

SPCdata http://spcdata.digitpa.gov.it:8899/sparql

Page 43: #sod14 - ok, è un endpoint SPARQL non facciamoci prendere dal panico

l’esempio di oggi

select distinct ?o where {[] a ?o}

select ?o count(distinct ?s) where {?s a ?o}

select count(?s) where {?s ?p ?o}

select count(?s) ?class where {?s ?p ?o; a ?class}

select distinct ?p where {?s a <http://dati.camera.it/ocd/legge>; ?p ?o}

select ?p count(?p) where {?s a <http://dati.camera.it/ocd/legge>; ?p ?o}

select ?s where {?s a <http://dati.camera.it/ocd/legge>} LIMIT 100

select distinct ?p ?o where {<http://dati.camera.it/ocd/legge.rdf/L1948_1102> ?p ?o}

select distinct ?p ?o ?p1 ?o2 where {<http://dati.camera.it/ocd/legge.rdf/L1948_1102> ?p ?o. OPTIONAL{?o ?p1 ?o2. FILTER(isBlank(?o))}}

select distinct ?s ?title where {?s a <http://dati.camera.it/ocd/legge>; dc:title ?title. FILTER(REGEX(?title,’indennit’,’i’) AND REGEX(?title,’parlament’,’i’))} LIMIT 100