Semantic Information Craft with Drupal

seaurchininterpreterInternet and Web Development

Dec 7, 2013 (3 years and 6 months ago)

173 views

Knowledge Graph

XHTML+RDFa

[D7] HTML
"
Header
"
: Standard

<!DOCTYPE
html

PUBLIC c
-
//W3C//DTD XHTML+
RDFa

1.0//EN"


"http://www.w3.org/
MarkUp
/DTD/
xhtml
-
rdfa
-
1.dtd
">


<
html

xmlns
=http://www.w3.org/1999/
xhtml

xml:lang="en"
version
="XHTML+
RDFa

1.0" dir="ltr">


<
head

profile
="http://www.w3.org/1999/
xhtml
/
vocab
">


[D7] HTML
"
Header
"
: Extended


After the
activation

of the
core

module

RDF


there

are

9
more

namespace

references

in the HTML
head

part.
And,
after

activating

the
contrib

module

RDF
Extensions

(
RDFx
)
there

are
/
can

be
even

more
!


This
,
especially

RDFx
,
lays

the
foundation

for a
more

precise

and extensive
semantization

of the
content
.


Once

upon

a time the
semantization

was not
done

at
particular

HTML
elements

directly
, but
solely

in the HTML
header
:


<
meta

property
="
og
:
image
"


content
="http
://foobar.tld/pic
-
for
-
facebook.png" />

[D7] Core RDF

The
core

RDF

module

is

activated

as

a default!

[D7] Core RDF

First basic steps

Activate
core
RDF

module.


Check content type:

No RDF settings
available yet!


Download contrib module

RDF Extensions

from
drupal.org/project/
rdfx
.


Entity

module is a dependency!


ARC2

library is a requirement!


[D7]
RDFx


Path
: /
admin
/
modules



After
activation

you

will
find

RDF publishing
settings

on

/
admin
/
config
/
services
/
rdf

.


But
nothing

in
this

overview

is

yet
editable
!


[D7] RDF publishing
settings


Path
: /
admin
/
config
/
services
/
rdf


[D7] RDF publishing settings

http://youtu.be/qbU2j_3ItGA


[D7]
Add

external

Namespaces


Path
: /
admin
/
config
/
services
/
rdf


Sample


Prefix
:
hmedia


NS URI:
http://purl.org/microformat/hmedia/


Exotic

vocabulary
/
namespace
.
Testing
!

[D7] The Tabulator Extension


Firefox Add
-
on
The Tabulator Extension


http://
dig.csail.mit.edu/2007/tab
/



Displays semantic data in various formats.


Possibly not available for newer FF versions.


More about semantic tools later!


The 2
contrib

modules



Microdata



Schema.org

Microdata

Microdata

What

is

SPARQL?

The 2
contrib

modules



SPARQL
Views



VARQL

What is SPARQL?


SPARQL is an acronym and stands for

"
S
imple
P
rotocol
A
nd
R
DF
Q
uery
L
anguage

"


You

can

query
semantic
, open data
sources

with

it.

And
retrieve

structured data
like

that
.



SPARQL
resembles
/
equals

formally

SQL for DBS


Two

current

D7
tutorials
:


http://ibm.com/developerworks/web/library/wa
-
rdf/



http://ibm.com/developerworks/web/library/wa
-
datasets/



SELECT ?person WHERE { ?person
dbo:birthPlace

<http://dbpedia.org/resource/Oxford> . }

[D7] SPARQL Modules


SPARQL


http://drupal.org/project/sparql


"
SPARQL is a query language for pattern matching against
RDF graphs. The syntax resembles SQL, making for a
friendly learning curve, but SPARQL is far more powerful,
enabling queries spanning multiple disparate (local or
remote) data sources containing heterogeneous
semistructured data.
"


This module also enables your site
to be queried
!

Drupledge Graph?

Tools


Firefox add
-
on "The Tabulator Extension"


http://dig.csail.mit.edu/2007/tab/



http://dig.csail.mit.edu/2007/tab/tabtutorial.html



Protégé
, a cost
-
free ontology software


http://protege.stanford.edu



RDFa Visualizer:
http://rdfa.info/play/



Altova Missionkit for XML Developers


is a commercial and huge semantic software suite


http://altova.com