SHACL validation with pySHACL¤
Python Plugin
This operator is part of a Python Plugin Package. In order to use it, you need to install it, e.g. with cmemc.
Performs SHACL validation with pySHACL. Select a Data graph and a SHACL shapes graph to get started. The plugin can output Entities, and/or produce a more detailed Validation graph by specifying a Validation graph URI. Additional configuration parameters can be set to control the output generated by the plugin. Refer to each parameter description for details.
Parameter¤
Data graph URI¤
The URI of the graph to be validated. The graph URI is selected from a list of graphs of types void:Dataset, shui:ShapeCatalog, owl:Ontology and dsm:ThesaurusProject.
- ID:
data_graph_uri - Datatype:
string - Default Value:
None
SHACL shapes graph URI¤
The URI of the graph containing the SHACL shapes to be validated against. The graph URI is selected from a list of graphs of type shui:ShapeCatalog.
- ID:
shacl_graph_uri - Datatype:
string - Default Value:
None
Generate validation graph¤
If enabled, the validation graph is posted to the CMEM instance with the graph URI specified with the Validation graph URI option.
- ID:
generate_graph - Datatype:
boolean - Default Value:
false
Validation graph URI¤
If the Generate validation graph option is enabled the validation graph is posted to the CMEM instance with this graph URI.
- ID:
validation_graph_uri - Datatype:
string - Default Value:
None
Output entities¤
If enabled, the plugin outputs the validation results as entities and can be connected to, for instance, a CSV dataset to produce a results table.
- ID:
output_entities - Datatype:
boolean - Default Value:
false
Clear validation graph¤
If enabled, the validation graph is cleared before workflow execution.
- ID:
clear_validation_graph - Datatype:
boolean - Default Value:
true
Advanced Parameter¤
Ontology graph URI¤
The URI of a graph containing extra ontological information. RDFS and OWL definitions from this are used to inoculate the data graph. The graph URI is selected from a list of graphs of type owl:Ontology.
- ID:
ontology_graph_uri - Datatype:
string - Default Value:
None
Resolve owl:imports¤
If enabled, the graph tree defined with owl:imports in the data graph is resolved.
- ID:
owl_imports - Datatype:
boolean - Default Value:
true
Blank node skolemization¤
If enabled, blank nodes in the validation graph are skolemized into URIs.
- ID:
skolemize - Datatype:
boolean - Default Value:
true
Add labels¤
If enabled, rdfs:label triples are added to the validation graph for instances of sh:ValidationReport and sh:ValidationResult.
- ID:
add_labels - Datatype:
boolean - Default Value:
true
Add labels to focus nodes and values¤
If enabled along with the Add labels option, rdfs:label triples are added for the focus nodes, values and SHACL shapes in the validation graph. The labels are taken from the specified data and SHACL graphs.
- ID:
include_graphs_labels - Datatype:
boolean - Default Value:
false
Add shui:conforms flag to focus node resources.¤
If enabled, shui:conforms false triples are added to the focus nodes in the validation graph.
- ID:
add_shui_conforms - Datatype:
boolean - Default Value:
false
Meta-SHACL¤
If enabled, the SHACL shapes graph is validated against the SHACL-SHACL shapes graph before validating the data graph.
- ID:
meta_shacl - Datatype:
boolean - Default Value:
false
Inference¤
If enabled, OWL inferencing expansion of the data graph is performed before validation. Options are RDFS, OWLRL, Both, None.
- ID:
inference - Datatype:
string - Default Value:
none
SHACL advanced features¤
Enable SHACL advanced features.
- ID:
advanced - Datatype:
boolean - Default Value:
false
SHACL-JS features¤
Enable SHACL-JS features.
- ID:
js - Datatype:
boolean - Default Value:
false
Remove graph type http://rdfs.org/ns/void#Dataset from data graph¤
Before validating, remove the triple <data_graph_uri> a <http://rdfs.org/ns/void#Dataset> from the in-memory data graph.
- ID:
remove_dataset_graph_type - Datatype:
boolean - Default Value:
false
Remove graph type https://vocab.eccenca.com/dsm/ThesaurusProject from data graph¤
Before validating, remove the triple <data_graph_uri> a <https://vocab.eccenca.com/dsm/ThesaurusProject> from the in-memory data graph.
- ID:
remove_thesaurus_graph_type - Datatype:
boolean - Default Value:
false
Remove graph type https://vocab.eccenca.com/shui/ShapeCatalog from data graph¤
Before validating, remove the triple <data_graph_uri> a <https://vocab.eccenca.com/shui/ShapeCatalog> from the in-memory data graph.
- ID:
remove_shape_catalog_graph_type - Datatype:
boolean - Default Value:
false
Specify a custom max-evaluation-depth¤
specify a custom max-evaluation-depth. If you find yourself with a legitimate use case, and you are certain you need to increase this limit, and you are cetain you know what you are doing.
- ID:
max_validation_depth - Datatype:
Long - Default Value:
15