You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2021/04/19 16:13:47 UTC
[jena-site] branch rdfs created (now 737c2dd)
This is an automated email from the ASF dual-hosted git repository.
andy pushed a change to branch rdfs
in repository https://gitbox.apache.org/repos/asf/jena-site.git.
at 737c2dd JENA-2089: Documentation for Data+RDFS
This branch includes the following new commits:
new be176d6 Fix alias URL
new 7fe590c Fix section headers
new 737c2dd JENA-2089: Documentation for Data+RDFS
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[jena-site] 02/03: Fix section headers
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
andy pushed a commit to branch rdfs
in repository https://gitbox.apache.org/repos/asf/jena-site.git
commit 7fe590ce226d6ebb884ce95d33fb6b0e9000e5a0
Author: Andy Seaborne <an...@apache.org>
AuthorDate: Mon Apr 19 17:12:45 2021 +0100
Fix section headers
---
source/documentation/inference/__index.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/source/documentation/inference/__index.md b/source/documentation/inference/__index.md
index 6d59c81..f7d8b81 100644
--- a/source/documentation/inference/__index.md
+++ b/source/documentation/inference/__index.md
@@ -571,7 +571,7 @@ slug: index
.addProperty(ReasonerVocabulary.PROPsetRDFSLevel, "simple");
Reasoner reasoner = RDFSRuleReasonerFactory.theInstance()Create(config);
-####Summary of parameters
+#### Summary of parameters
<table width="90%" border="1" cellspacing="0" cellpadding="0">
<tr>
<td width="22%"><b>Parameter</b></td>
@@ -1209,7 +1209,7 @@ class B = cardinality(P,1)</pre>
of rule use and a substantial slow down - the OWL axioms that the reasoner can
handle are already built in and don't need to be redeclared.</p>
-####Incompleteness
+#### Incompleteness
<p>The rule based approach cannot offer a complete solution for OWL/Lite, let
alone the OWL/Full fragment corresponding to the OWL/Lite constructs. In addition
the current implementation is still under development and may well have omissions
[jena-site] 01/03: Fix alias URL
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
andy pushed a commit to branch rdfs
in repository https://gitbox.apache.org/repos/asf/jena-site.git
commit be176d6347a64f24406b3426b9b5025c4f9ec6b6
Author: Andy Seaborne <an...@apache.org>
AuthorDate: Mon Apr 19 17:12:24 2021 +0100
Fix alias URL
---
source/documentation/rdf-star/__index.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/source/documentation/rdf-star/__index.md b/source/documentation/rdf-star/__index.md
index e33cc6d..b61bc39 100644
--- a/source/documentation/rdf-star/__index.md
+++ b/source/documentation/rdf-star/__index.md
@@ -2,7 +2,7 @@
title: Support of RDF-star
slug: index
aliases:
- - /docimentation/rdfstar/
+ - /documentation/rdfstar/
- /documentation/rdfstar/index.html
---
[jena-site] 03/03: JENA-2089: Documentation for Data+RDFS
Posted by an...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
andy pushed a commit to branch rdfs
in repository https://gitbox.apache.org/repos/asf/jena-site.git
commit 737c2dd703a2d1186bdea8c6188c4d4e2c72a092
Author: Andy Seaborne <an...@apache.org>
AuthorDate: Mon Apr 19 17:13:28 2021 +0100
JENA-2089: Documentation for Data+RDFS
---
source/documentation/rdfs/__index.md | 187 +++++++++++++++++++++++++++++++++++
1 file changed, 187 insertions(+)
diff --git a/source/documentation/rdfs/__index.md b/source/documentation/rdfs/__index.md
new file mode 100644
index 0000000..cb3d948
--- /dev/null
+++ b/source/documentation/rdfs/__index.md
@@ -0,0 +1,187 @@
+---
+title: Data with RDFS Inferencing
+slug: index
+---
+
+This page describes support for accessing data with additional statements
+derived using RDFS. It supports `rdfs:subClassOf`, `rdfs:subPropertyOf`, `rdfs:domain` and `rdfs:range`. It
+does not provide RDF axioms. The RDFS vocabulary is not included in the data.
+
+It does support use with RDF datasets, where each graph in the dataset has the
+same RDFS vocabulary applied to it.
+
+This is not a replacement for the [Jena RDFS Reasoner support](/inference/)
+which covers full RDFS inference.
+
+The data is updateable, and graps can be added and removed from the dataset.
+The vocabulary can not be changed during th elifetime of the RDFS dataset.
+
+### API: `RDFSFactory`
+
+The API provides operation to build RDF-enabled datasets from data storage and vocabularies:
+
+Example:
+```
+ DatasetGraph data = ...
+ // Load the vocabulary
+ Graph vocab = RDFDataMgr.loadGraph("vocabulary.ttl");
+ // Create a DatsetGraph with RDFS
+ DatasetGraph dsg = datasetRDFS(DatasetGraph data, Graph vocab );
+ // (Optional) Present as a Dataset.
+ Dataset dataset = DatasetFactory.wrap(dsg);
+```
+
+The vocabulary is processed to produce datastructure needed for processing he
+data eficiently at run time. This is the `SetupRDFS` class that can be created
+and shared; it is thread-safe.
+
+```
+ SetupRDFS setup = setupRDFS(vocab);
+```
+
+### Assembler: RDFS Dataset
+
+Datasets with RDFS can built with an assembler:
+
+```
+<#rdfsDS> rdf:type ja:DatasetRDFS ;
+ ja:rdfsSchema <vocabulary.ttl>;
+ ja:dataset <#baseDataset> ;
+ .
+
+<#baseDataset> rdf:type ...some dataset type ... ;
+ ...
+ .
+```
+where `<#baseDataset>` is the definition of the dataset to be enriched.
+
+### Assembler: RDFS Graph
+
+It is possible to build a single `Model`:
+
+```
+ <#rdfsGraph> rdf:type ja:GraphRDFS ;
+ ja:rdfsSchema <vocabulary.ttl>;
+ ja:graph <#baseGraph> ;
+ .
+
+ <#baseGraph> rdf:type ja:MemoryModel;
+ ...
+```
+
+More generally, inference models can be defined using the Jena Inference and Rule
+engine:
+[jena-fuseki2/examples/config-inference-1.ttl](https://github.com/apache/jena/tree/main/jena-fuseki2/examples/config-inference-1.ttl).
+
+## Use with Fuseki
+
+The files for this example are available at:
+[jena-fuseki2/examples/rdfs](https://github.com/apache/jena/tree/main/jena-fuseki2/examples/rdfs).
+
+From the command line (here, loading data from a file into an in-memory dataset):
+```
+fuseki-server --data data.trig --rdfs vocabulary.ttl /dataset
+```
+
+or from a configuration file with an RDFS Dataset:
+
+```
+PREFIX : <#>
+PREFIX fuseki: <http://jena.apache.org/fuseki#>
+PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
+PREFIX ja: <http://jena.hpl.hp.com/2005/11/Assembler#>
+
+[] rdf:type fuseki:Server ;
+ fuseki:services (
+ :service
+ ) .
+
+## Fuseki service /dataset with SPARQ query
+## /dataset?query=
+:service rdf:type fuseki:Service ;
+ fuseki:name "dataset" ;
+ fuseki:endpoint [ fuseki:operation fuseki:query ] ;
+ fuseki:endpoint [ fuseki:operation fuseki:update ] ;
+ fuseki:dataset :rdfsDataset ;
+ .
+
+## RDFS
+:rdfsDataset rdf:type ja:DatasetRDFS ;
+ ja:rdfsSchema <file:vocabulary.ttl>;
+ ja:dataset :baseDataset;
+ .
+
+## Transactional in-memory dataset.
+:baseDataset rdf:type ja:MemoryDataset ;
+ ja:data <file:data.trig>;
+ .
+```
+
+### Querying the Fuseki server
+
+With the [SOH](/documentation/fuseki2/soh.html) tools, a query (asking for plain
+text output):
+```
+s-query --service http://localhost:3030/dataset --output=text --file query.rq
+```
+
+or with `curl`:
+
+```
+curl --data @query.rq \
+ --header 'Accept: text/plain' \
+ --header 'Content-type: application/sparql-query' \
+ http://localhost:3030/dataset
+```
+
+will return:
+
+```
+-------------------------
+| s | p | o |
+=========================
+| :s | ns:p | :o |
+| :s | rdf:type | ns:D |
+| :o | rdf:type | ns:T1 |
+| :o | rdf:type | ns:T3 |
+| :o | rdf:type | ns:T2 |
+-------------------------
+```
+
+### Files
+
+data.trig:
+```
+PREFIX : <http://example/>
+PREFIX ns: <http://example/ns#>
+
+:s ns:p :o .
+```
+
+`vocabulary.ttl`:
+
+```
+PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
+PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
+PREFIX skos: <http://www.w3.org/2008/05/skos#>
+PREFIX list: <http://jena.hpl.hp.com/ARQ/list#>
+
+PREFIX ns: <http://example/ns#>
+
+ns:T1 rdfs:subClassOf ns:T2 .
+ns:T2 rdfs:subClassOf ns:T3 .
+
+ns:p rdfs:domain ns:D .
+ns:p rdfs:range ns:T1 .
+```
+
+`query.rq`:
+```
+PREFIX : <http://example/>
+PREFIX ns: <http://example/ns#>
+PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
+
+SELECT * { ?s ?p ?o }
+```