Skip to content

Convert SHACL to ShEx #113

Description

@labra

Implement a conversion from SHACL-core to ShEx.

The converter has already been started although some features are not implemented yet. We will keep this issue open to track the features that are implemented and the issues found.

Features:

SHACL features based on: SHACL recommendation

Target selection

Simple target selection can be mapped to ShEx shape maps.

| Feature | |
| --- | --- | --- |
| Target Node sh:targetNode | ❌ | Pending shapeMaps conversion |
| Class-based targets sh:targetClass | ❌ | Pending shapeMaps conversion |
| Implicit class targets | ❌ | Pending shapeMaps conversion |
| Subjects of targets sh:targetSubjectsOf | ❌ | Pending shapeMaps conversion |
| Objects of targets sh:targetObjectsOf | ❌ | Pending shapeMaps conversion |

Shapes

Feature Supported Comments
sh:name Could be done with annotations
sh:description Could be done with annotations
sh:group Could be done with annotations
sh:order Could be done with annotations
owl:imports
sh:entailment
sh:shapesGraph

Validation report

Feature Supported Pending
sh:deactivated
sh:message
sh:severity

Constraints

Feature Supported Pending
Node constraints ✔️
Property shapes (sh:path) ✔️
Path constraints This feature is not easy to map between ShEx and SHACL

Constraint components

Feature Supported Pending Comments
sh:class
sh:datatype ✔️
sh:nodeKind ✔️
sh:minCount ✔️
sh:maxCount ✔️
sh:minInclusive, sh:maxInclusive, sh:minExclusive, sh:maxExclusive
sh:minLength
sh:maxLength
sh:pattern
sh:flags
sh:languageIn
sh:uniqueLang
sh:equals
sh:disjoint
sh:lessThan This feature is not easy in ShEx
sh:lessThanOrEquals This feature is not easy in ShEx
sh:not
sh:and
sh:or
sh:xone
sh:node
sh:qualifiedValueshape, qualifiedMinCount, qualifiedMaxCount
sh:qualifiedValueshapesDisjoint
sh:closed
sh:ignoredProperties
sh:hasValue
sh:in

SPARQL based constraints

(:x:) Non-supported

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions