developing distributed semantic systems

32
Building Distributed Semantic Systems Antonio Garrote Hernández Monday, December 21, 2009

Upload: antoniogarrote

Post on 15-Jan-2015

430 views

Category:

Education


0 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Developing Distributed Semantic Systems

Building Distributed Semantic Systems

Antonio Garrote Hernández

Monday, December 21, 2009

Page 2: Developing Distributed Semantic Systems

Definition

• Distributed processes

• Semantic meta data exposed as resources

• Triple space operations

• RESTful interface

Monday, December 21, 2009

Page 3: Developing Distributed Semantic Systems

Different abstraction levels

Monday, December 21, 2009

Page 4: Developing Distributed Semantic Systems

Monday, December 21, 2009

Page 5: Developing Distributed Semantic Systems

Sample application

Monday, December 21, 2009

Page 6: Developing Distributed Semantic Systems

• Sensor processes monitoring generation of exceptions in different nodes and languages/platforms

• Aggregator processes retrieving the exceptions and creating Exception resources

• Exception RESTful semantic web service

• Web client displaying generated exceptions

Exception logging system

Monday, December 21, 2009

Page 7: Developing Distributed Semantic Systems

Methodology

Monday, December 21, 2009

Page 8: Developing Distributed Semantic Systems

4 step process

1. Knowledge modeling

2. Formal description

3. Implementation of RESTful semantic services

4. Implementation of client processes

Monday, December 21, 2009

Page 9: Developing Distributed Semantic Systems

1.Knowledge modeling

Monday, December 21, 2009

Page 10: Developing Distributed Semantic Systems

1.Knowledge modeling

• Building of an ontology for the problem domain

• Ontology = TBox in Description Logics

• Use of W3C’s standard languages: RDFS or OWL

• Assistance of graphical tools like Protégé

Monday, December 21, 2009

Page 11: Developing Distributed Semantic Systems

Exception

generatedplatform

level message createdAt

ipAddress domain dc:title formatPattern

Node Language

Sample application ontology

Monday, December 21, 2009

Page 12: Developing Distributed Semantic Systems

Developing the sample application ontology with Protégé

Monday, December 21, 2009

Page 13: Developing Distributed Semantic Systems

Ontology(<http://semantic_rest/exceptions.owl>

Declaration(Class(Exception))SubClassOf(Exception owl:Thing)Declaration(Class(Node))SubClassOf(Node owl:Thing)Declaration(Class(ProgrammingLanguage))SubClassOf(ProgrammingLanguage owl:Thing)

Declaration(ObjectProperty(platform))ObjectPropertyDomain(platform Exception)ObjectPropertyRange(platform ProgrammingLanguage)

Declaration(ObjectProperty(generatedIn))ObjectPropertyDomain(generatedIn Exception)ObjectPropertyRange(generatedIn Node)

Declaration(DataProperty(level))DataPropertyDomain(level Exception)DataPropertyRange(level rdfs:Literal)

Declaration(DataProperty(ipAddress))DataPropertyDomain(ipAddress Node)DataPropertyRange(ipAddress xsd:string)

Declaration(DataProperty(formatPattern))DataPropertyDomain(formatPattern Exception)DataPropertyRange(formatPattern xsd:string)

Declaration(DataProperty(createdAt))DataPropertyDomain(createdAt Exception)DataPropertyRange(createdAt xsd:dateTime)

Declaration(DataProperty(content))DataPropertyDomain(content Exception)DataPropertyRange(content xsd:string)

Declaration(DataProperty(domain))DataPropertyDomain(domain Node)DataPropertyRange(domain rdfs:Literal))

Resulting ontologyusing OWL

Functional Notation

Monday, December 21, 2009

Page 14: Developing Distributed Semantic Systems

2.Formal description

Monday, December 21, 2009

Page 15: Developing Distributed Semantic Systems

• Formal description of the whole distributed system

• Concerned with ‘dynamic’ aspects of the system

• Use of an extended version of the Pi-Calculus

Monday, December 21, 2009

Page 16: Developing Distributed Semantic Systems

S(r)

S(j)

TEAEWGET subscribe n POST n

Formal description of the sample application

Monday, December 21, 2009

Page 17: Developing Distributed Semantic Systems

Formal description of the sample application

Processes equations:

Monday, December 21, 2009

Page 18: Developing Distributed Semantic Systems

3.Implementation of RESTful semantic

services

Monday, December 21, 2009

Page 19: Developing Distributed Semantic Systems

• 1 RESTful semantic service per OWL/RDFS class in the ontology

• Use of the Plaza Framework developed for building RESTful semantic web services

Monday, December 21, 2009

Page 20: Developing Distributed Semantic Systems

• OWL/RDFS class triples

• Exposed as a RESTful resource

• Conceptually equivalent to a Linda triple space

RESTful Semantic Web Service

Monday, December 21, 2009

Page 21: Developing Distributed Semantic Systems

Service’s InterfaceCreate POST

Read GET

Blocking read GET + xblocking header

Subscribe • GET + xsubscribe header• Websockets

Update PUT

Destroy DELETE

Monday, December 21, 2009

Page 22: Developing Distributed Semantic Systems

resourcetriplespace

REST Resource

HTTP request

triple space op.

RDF Graph

SPARQL query

Lifting

Lowering

Monday, December 21, 2009

Page 23: Developing Distributed Semantic Systems

Plaza Framework

Monday, December 21, 2009

Page 24: Developing Distributed Semantic Systems

Plaza Framework

• Manages ‘Plaza Applications’: OWL ontolgy + configuration module + resources modules

• Declarative: almost no coding required

• Support for different Java RDF repositories

• Automatic managing of triples through the concepts of write-tree and read-tree for the resources

• Support for the subscribe operation through chunked HTTP responses and websockets

Monday, December 21, 2009

Page 25: Developing Distributed Semantic Systems

Sample application configuration module

Monday, December 21, 2009

Page 26: Developing Distributed Semantic Systems

Sample application exceptions resource module

Monday, December 21, 2009

Page 27: Developing Distributed Semantic Systems

4.Implementation of client processes

Monday, December 21, 2009

Page 28: Developing Distributed Semantic Systems

• Client processes are just REST clients

• Required libraries: HTTP and triples format parser (RDF/XML, Turtle, JSON)

• Optional support for Websockets

• Clojure library included as part of the Plaza Framework

Monday, December 21, 2009

Page 29: Developing Distributed Semantic Systems

Clojure implementation of the sensor and aggregator processes

Monday, December 21, 2009

Page 30: Developing Distributed Semantic Systems

Javascript web client using websockets

Monday, December 21, 2009

Page 31: Developing Distributed Semantic Systems

Web client execution

Monday, December 21, 2009

Page 32: Developing Distributed Semantic Systems

• Semantic technologies enable rich description of problem domains vs. relational modeling

• Formal description of distributed systems enables reasoning about its validity and correctness

• RESTful semantic web services enable easy access to semantic data

• Building RESTful semantic web services clients is trivial due to the use of well known HTTP standard

• Triple Space operations are powerful coordination mechanisms for distributed processes

Conclusions

Monday, December 21, 2009