background preloader

SPIN - SPARQL Inferencing Notation

Facebook Twitter

SPIN is a W3C Member Submission that has become the de-facto industry standard to represent SPARQL rules and constraints on Semantic Web models. SPIN also provides meta-modeling capabilities that allow users to define their own SPARQL functions and query templates.

Finally, SPIN includes a ready to use library of common functions. Uml2owl-specs. About this Document The purpose of this document is to provide specifications of the model-based transformations that allow a UML model to be converted to OWL. TopQuadrant's TopBraid platform provides the foundations for the transformations.

Specific UML2OWL libraries hold the SPARQL SPIN rules for converting UML to OWL. The document was generated using TopQuadrant's templating language SWP. Technical Overview The methodology for the transformation of UML models to OWL comprises: Configuration of OWL namespaces for packages Import of the XMI model from the UML tool Conversion of the UML package and class models to OWL models Export of the transformed models The XMI specifications of UML package and class models are converted to OWL class models by means of ontology-driven transformation rules. Currently the transformations support XMI version 2.1 and XMI extensions as defined by Sparx Systems Enterprise Architect.

Model Specifications Semantic XML - XML to RDF CMOF Model XMI Standard Classes. SPIN Result Sets, Tables and Spreadsheets Vocabulary. Abstract This document describes the SPR vocabulary: a collection of classes, properties and SPARQL functions that can be used to process tabular data in RDF. The tabular data may originate from the result sets of SPARQL SELECT queries, from external spreadsheet files or from user input. SPR does not prescribe details on the storage of the tabular data, e.g. as RDF triples, but instead only defines an abstract interface of SPARQL functions that can be used to query, iterate through and aggregate tabular data.

Status of This Document This document is an optional part of the SPARQL Inferencing Notation (SPIN) specification. 1 Introduction Having RDF-based projects operate on tabular data is a very common scenario. There is no standard way of storing tabular data in RDF. The SPIN Result Sets, Tables and Spreadsheets (SPR) Vocabulary is a collection of SPIN functions that can be used to query tabular data from SPARQL queries. This document enumerates the main functions of the SPR vocabulary. ? ? SPIN JavaScript Functions (SPINx) Abstract This document describes the SPINx vocabulary, an extension of the SPIN framework that can be used to define new SPARQL functions based on JavaScript code. This makes it possible to extend SPARQL engines with new functions that execute JavaScript at run-time. The SPINx framework is very light-weight and is easy to implement and use. Status of This Document This document is an optional part of the SPARQL Inferencing Notation (SPIN) specification. 1 Introduction While SPARQL is an immensely powerful language, many real-world use cases require extensions that are not covered by the official standards.

Those user-defined SPIN functions are a very powerful way of extending SPARQL, but they are still limited by whatever features are natively supported by the executing SPARQL engine. The following sections introduce the two properties of the SPINx vocabulary. 2 spinx:javaScriptCode The simplest way of defining a JavaScript-based SPIN function is by using the property spinx:javaScriptCode. SPIN - SPARQL Inferencing Notation. The SPIN Technology Stack. The SPIN Stack is a group of industrial-strength technologies that can be used to build real-world solutions with Semantic Web standards. Hardened over many years of exposure to customer requirements and supported by professional development tools, the SPIN Stack provides a complete solution platform for building services and applications that operate on linked data.

The SPIN Stack is fully supported by TopQuadrant's TopBraid Suite. An overview of the various technologies involved in this family of languages is provided in the figure below. The foundation of the various SPIN languages is RDF, which also serves as the base infrastructure of the W3C Semantic Web activity including the higher level language RDF Schema and the various modeling languages such as OWL, SKOS etc. The standard Semantic Web query language SPARQL plays a key role in the SPIN framework. SWP extends SPIN with additional vocabulary to link domain concepts with user interface descriptions. SPIN (SPARQL Inferencing Notation) | TopQuadrant, Inc. SPIN in Five Slides. SPIN - Overview and Motivation. Abstract This document provides an overview of the SPARQL Inferencing Notation (SPIN). SPIN is a SPARQL-based rule and constraint language for the Semantic Web.

SPIN is also a mechanism to represent reusable SPARQL queries as templates and to define new SPARQL functions with a web-friendly syntax. Status of This Document This section describes the status of this document at the time of its publication. Other documents may supersede this document. This document is part of the SPIN Submission which comprises three documents: Earlier versions of the SPIN specification have been published by the informal SPIN working group at By publishing this document, W3C acknowledges that the Submitting Members have made a formal Submission request to W3C for discussion. The current stack of modeling languages for the web of data provide excellent mechanisms for capturing the static structure of data. Acknowledgments References.

SPIN - SPARQL Syntax. Abstract This document describes the SPIN SPARQL Syntax, an RDF representation of the semantic web query language SPARQL. The SPIN SPARQL Syntax provides an alternative representation of SPARQL queries that goes beyond the textual format. The main benefit of this syntax is that it makes it possible to consistently store SPARQL queries together with the domain model. All resources from the domain model are represented as proper RDF resource references instead of only having them as strings. Status of This Document SPIN has originally evolved as a specification developed by TopQuadrant. 1 Overview The design of the SPIN SPARQL Syntax was motivated by the need to have a machine-readable notation of SPARQL queries so that they can be stored together with other domain models and ontologies in RDF format.

For example, the SPARQL query can be represented by a blank node in the SPIN RDF Syntax in Turtle as In a typical scenario, each SPARQL query is stored as a (tree) structure of blank nodes. ? ? The SPIN Standard Modules Library. Abstract SPIN provides a mechanism to encapsulate SPARQL queries into reusable building blocks so that they can be shared on the Semantic Web. In particular, SPIN makes it possible to define new SPARQL functions and query templates together with definitions of their arguments. The SPIN Standard Modules Library (SPL) is a collection of such SPIN functions and templates that might be of general use. Among others, this library covers some common domain modeling patterns such as attribute declarations with cardinality and value range constraints. SPL also declares the standard SPARQL functions like ! = and bound. Status of This Document This document is part of the SPARQL Inferencing Notation (SPIN) specification. 1 Introduction The SPIN Standard Modules Library has been designed to provide a small collection of frequently needed SPARQL queries.

Potentially such a library could comprise domain specific features such as geospatial functions, unit conversion, or mathematical utilities. 2 Functions. SPIN Result Sets, Tables and Spreadsheets Vocabulary. SPIN JavaScript Functions (SPINx) SPIN Modeling Vocabulary. Abstract The SPIN Modeling Vocabulary is a light-weight collection of RDF properties and classes to support the use of SPARQL to specify rules and logical constraints. Based on an RDF representation of SPARQL queries, SPIN defines three class description properties: spin:constraint can be used to define conditions that all members of a class must fulfill. spin:rule can be used to specify inference rules using SPARQL CONSTRUCTs and DELETE/INSERTs. spin:constructor can be used to initialize new instances with default values. In addition to these class description properties, SPIN provides a powerful meta-modeling capability that can be used to build your own modeling language and SPARQL extensions.

These meta-modeling features provide the ability to encapsulate reusable SPARQL queries into templates, and to derive new SPARQL functions as well as magic properties from other SPARQL queries and functions. Status of This Document 1 Introduction 2 Class Description Vocabulary 2.1 Constraints. SPIN Primer: Rectangles and Squares. Editor: Holger Knublauch, TopQuadrant, Inc. This document introduces SPIN to people familiar with basic concepts of RDF and SPARQL. A simple model about rectangles and squares is used to introduce all major features of SPIN, including class definitions, constraints, rules, functions and templates. This document can serve as the "Hello, World" example of SPIN. Table of Contents 1. SPIN - the SPARQL Inferencing Notation - is a W3C Member Submission that can be used to create rich semantic models based on SPARQL.

This document uses a running example model illustrated in the following UML diagram. The Turtle source code of the complete SPIN file can be found at 2. SPIN makes it possible to attach executable rules to classes. The example above introduces some basic concepts of SPIN: SPARQL queries are represented as RDF resource of type sp:Construct, sp:Ask or sp:Select (depending on whether they are CONSTRUCT, ASK or SELECT queries). 3. 4. 5. SPINTutorial-1.0.pdf. Using SPARQL and SPIN for Data Quality Management on the Semantic Web.

SemWebQuality.org. SPIN Mini Profile. Draft for a minimum subset of SPIN for the RDF Shapes WG Authors: Holger Knublauch <holger@topquadrant.com> updated 23 July, 2014 Abstract This document outlines a minimum sub-set of SPIN that tries to address some of the goals of the RDF Shapes working group (Charter). SPIN Vocabulary Namespace prefixes used: sp : < spin : < spl : < SPARQL CONSTRUCT queries are represented by blank nodes of the class sp:Construct with a property sp:text pointing at a SPARQL query string (all examples in Turtle): [ a sp:Construct ; sp:text """ CONSTRUCT { # ... } WHERE { # ... } """ ] SPIN constraints are SPARQL CONSTRUCT queries or corresponding template calls that are attached to an RDFS/OWL class via the property spin:constraint. SPIN templates are reusable SPARQL queries identified by an instance of spin:ConstructTemplate with a URI and a spin:body that can be parameterized with pre-bound variables.

SPIN RDF Syntax (Optional)