-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Derive shapes from maps #125
Comments
Shapes derived from the mapping don't necessarily describe the output graph of the pipeline, often there are post-processing steps after the mapping. Nevertheless, there are likely cases for which shapes derived from the mapping are useful (maybe also for troubleshooting pipelines or the mapping itself by validating intermediate results). Some things to consider, if shapes are derived from the mapping (in general, not related to the proposal in PR #126 ... more of a "notes-to-self"):
(Unrelated to this feature request, but related to the last point of the above list) Decoupling the mapping from the schema by means of pointing from the mapping to shape elements, rather than schema elements could be an option to facilitate handling schema changes (shape-first, shape-as-contract). My plan is to make xrm more hackable, in order to unlock possibilites for toolchain improvements outside of the xrm editor itself. Like #127 and #128 |
For one-time scaffolding, introspecting the shapes from the output graph of the pipeline might be an alternative. Here's a query to illustrate this, based on the construct query that SPEX is running in "introspection" mode. I used this in a customer project. Note: The query has dependencies on
|
Yes, I realised that too while thinking about my proposal. In museumplus it is just like that. The XRM is only temporary representation and has nothing in common with the final representation. Maybe I did not mention that precisely, but my idea was that shapes defined in XRM could also be unrelated to the mapping itself. -node-shape PersonNodeShape from PersonMapping {
+node-shape PersonNodeShape {
} That way one could take advantage of a simpler syntax although that would be slightly incomplete without nice support for vocabularies (re #14).
I cannot really comment on that but I'm intrigued about how hackability helps. Let's discuss that |
See also https://github.com/RMLio/RML2SHACL Paper: RML2SHACL: RDF Generation Is Shaping Up |
I would like to propose a new feature where minimal SHACL shapes are generated from the mappings. The purpose is to generate a starting point for defining more specific constraints over the output data. For example, given the mapping shown in the language reference
One would be able to produce a shape with minimal constraints.
It's important property shapes are named nodes, so that they would be extendable by adding properties in a separate document and merging them.
Give multiple mappings for same predicate might require
sh:or
or different node kind such assh:NamedNodeOrLiteral
To implement this feature, I would propose to slightly adapt (and also simplify) the feature proposed in #115. I will create a draft PR to illustrate
The text was updated successfully, but these errors were encountered: