-
Notifications
You must be signed in to change notification settings - Fork 33
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
Proposal for removing the domain assertion for 'sh:declare' #131
Comments
To summarize from #130, the main reasons for having sh:declare rdfs:domain owl:Ontology were
The main reason against this domain statement seems to be that it may cause an undesired inference of X rdf:type owl:Ontology if X is not (meant to be) an owl:Ontology. I have no strong opinion yet it seems the advantages outweigh the disadvantage. What specific problems does the inference of rdf:type owl:Ontology cause to anyone? |
One specific problem: prefix sd: <http://www.w3.org/ns/sparql-service-description#>
[ a sd:SPARQL11Query;
sh:declare [ sh:prefix "..."; sh:namespace "..." ] ]. ^ After reading the SHACL documentation I thought that this was ok. Later I discover, to my surprise, that I am actually asserting that my queries are ontologies.
I disagree with this, but also believe this is a rehash of #130. I have responded to this sentence there, since that is a much broader discussion. I have done so to keep this present issue small in scope / only about |
I suggest to use the weaker semantics of
That should give the hint to editors that the |
In light of
I agree that it would be best to remove the |
I think a property shape would be better so that tools that already deal with SHACL don't need to add additional semantics. A suggestion: #130 (comment) |
That's harder than you might think. AFAIK there needs to be a NodeShape from which it hangs to do any validation. So you need something like:
However this is still not a hint as it requires any resource that has Maybe there is another incantation that has the desired 'hint' effect. |
@wouterbeek -- It seems that you are asking that the SHACL ontology be revised because you misunderstood it. Rather, it seems that SHACL has done it's job if you processed your instance data with it, which you had intended to conform to the SHACL ontology, and found your misunderstanding was revealed as an issue in your data. I would suggest that for the long term, you change your use of For the immediate term, you might take a copy of the SHACL ontology and edit it for your own local use, changing your local instance of --
-- to --
-- which allows for an entity of any It is perhaps worth noting that schema.org substantially revised their own ontology in recent times, replacing many instances of We might consider making changes along similar lines to the SHACL ontology, if there were a volume of requests with somewhat better justification than "we misunderstood it." |
One other thing.
The thing that is not required is explicit declaration that the IRIs are instances of That text does not "explicitly allow It might be sufficiently clarified by adding a couple words, as --
We have somewhat more leeway to add a clarifying note to the spec, to this effect, than we do to change the ontology. It's still a non-trivial change to make happen, but it may be worthwhile. |
As a W3C point of process, I believe that the ontology managed in /ns/ is not normative, and can be changed very easily. @iherman can you clarify? The text in the specification would then not need changing, as not all subjects of sh:declare would be inferred to be owl:Ontologies ... just like the text says. |
@TallTed Thanks for this clarification! I indeed misinterpreted the text :-/ This means that Authors who want to assert predicate declarations for things that are not OWL ontologies should not use |
But it still remains that as far as the SHACL ontology is concerned the denotation of subject of triples with predicate sh:declare are OWL ontologies (unless SHACL is supposed to be violating the W3C Semantic Web standards). |
@pfps --
Yes. Is that a problem from your perspective? |
@wouterbeek a more generic mechanism to specify prefixes for things which are not ontologies (such as SPARQL endpoints, queries or datasets) seems useful and worthwhile. Perhaps it's an idea to propose an extension to the SPARQL service description vocabulary to subsume those terms from your vocabulary as part of the SPARQL 1.2 effort? |
@TallTed |
@jaw111 Good idea! Can you review it? It's over at w3c/sparql-dev#134. (You may be aware of more prior work, or correct my English :-P) |
I was not involved in the SHACL WG, I do not know who maintains the specification itself. But, without knowing the details, indeed, the ontology file is not normative. The content of Any such change would require some sort of a consensus of the community, obviously. |
But that's not what the text says. The text is (emphasis added):
The second sentence is the focus. That sentence says that the IRIs which are subjects of The reason this need not be explicitly declared is that they are instances of This may also be deduced through simple rdfs inference including the SHACL ontology. Errors have been made, by at least one human who misunderstood that sentence, in the construction of their own instance data. That is unfortunate, but correctable, with no impact on anyone else who has used or included the SHACL ontology in their own efforts. I am struggling to understand why changes to the SHACL ontology, which has been shown not to contain an error, continue to be discussed. I believe this issue (#131) should be closed without other action, for the same reason as its precursor which went very far into the weeds (#130) already has: The prose of the SHACL specification was simply misunderstood. Once that misunderstanding was addressed, the triple in the SHACL ontology which had previously been considered to be an error was shown to be in fact correct. As I noted earlier, a couple of words could be added to that sentence of the spec to clarify the intended meaning, but (like the |
Okay, then multiple people misunderstood that sentence because I read it exactly the same way as @wouterbeek. An editorial errata to make the domain of sh:declare more obvious would be appreciated :) |
Having thought about this, I now prefer to also delete the rdfs:domain triple. I want (and always wanted) to make this part of the SHACL-SPARQL vocabulary as applicable as possible. If the rdfs:domain is seen as an obstacle to adoption then by all means let's delete it. I thought the benefits of it were outweighing the disadvantages, because I didn't see harm in the extra inference, but it seems to bother people. For those who want this triple, it is easy to add back, however in RDF it is very difficult to delete a triple from a graph that is not under one's own control. |
I would prefer to change the predicate in the triple from |
…are rdfs:domain owl:Ontology and sh:prefixes rdfs:range owl:Ontology - the owl:Ontologies are merely a recommendation in the spec yet now cause no RDFS inferences
This is fixed by this merge, as discussed and circulated. I will contact the W3C staff to see how this file can go live on its URL. |
I'm proposing to remove the following triple from the SHACL vocabulary:
While there is a good use case for asserting prefix declarations for OWL ontologies, there are also good use cases for asserting prefix declarations for things that are not OWL ontologies. Examples include (SPARQL) queries, (SPARQL) endpoints, and datasets that are not OWL ontologies.
The removal of this triple will also make the SHACL vocabulary easier to understand and apply in light of the following paragraph from the SHACL standard document, which explicitly allows
sh:declare
to be asserted for resources that are not OWL ontologies:The text was updated successfully, but these errors were encountered: