-
Notifications
You must be signed in to change notification settings - Fork 34
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
types:Thread is one level too high in the subclass hierarchy #509
Comments
I'd suggest to defer resolution of this CP until clarification has been achieved about the meaning and use of the |
I don't think that will be necessary. The current definition of disjoint classes in UCO's []
a owl:AllDisjointClasses ;
owl:members (
core:UcoInherentCharacterizationThing
core:UcoObject
) ;
.
I think it would be helpful for us to approach whatever the working-group's 2.0.0 resolution is with only one design pattern, rather than the current pattern and patterns implemented without regard for Issue 509. |
I would concur that this CP is likely not encumbered by any questions with facets. And to clarify, Alex is correct above that core:UcoInherentCharacterizationThing and core:UcoObject are disjoint but it should also be noted (since the topic of facets weas raised in relation to this discussion) that core:Facet is a subclass of core:UcoInherentCharacterizationThing. All facets are "a grouping of characteristics unique to a particular inherent aspect of a UCO domain object". So, because of the assertion that core:UcoInherentCharacterizationThing and core:UcoObject are disjoint, it also follows that core:Facet and core:UcoObject are disjoint. |
…tory A follow-on patch will regenerate Make-managed files. References: * #509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
References: * #509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
One interesting issue arose in testing. I implemented the class of Competency Question 1.1 as an XFAIL test, and encountered that the Collections Ontology in some cases (including co:List
a owl:Class ;
rdfs:comment "This definition is excerpted from co:."@en ;
rdfs:subClassOf [
a owl:Class ;
owl:intersectionOf (
co:Bag
[
a owl:Restriction ;
owl:onProperty co:item ;
owl:allValuesFrom co:ListItem ;
]
) ;
] ;
. RDFS inferencing would look for This is the explanation for why the SHACL-SPARQL query looks more complex for the Collections Ontology side vs. UCO's side: PREFIX co: <http://purl.org/co/>
PREFIX core: <https://ontology.unifiedcyberontology.org/uco/core/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT $this
WHERE {
$this
rdfs:subClassOf*/(owl:intersectionOf/rdf:rest*/rdf:first)?/rdfs:subClassOf* co:Collection ;
rdfs:subClassOf* core:UcoObject ;
.
} This pattern is tested in PR 516 here. |
…ctures This patch reverts the test for subclasses of `co:Element` and `core:UcoObject`, which was implemented to enforce disjointedness of `core:UcoObject` and `core:UcoInherentCharacterizationThing`. Testing for classes declared as disjoint is delegated to more general mechanisms. No effects were observed on Make-managed files. References: * #509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
No effects were observed on Make-managed files. References: * ucoProject/UCO#509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
No effects were observed on Make-managed files. References: * ucoProject/UCO#509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
No effects were observed on Make-managed files. References: * ucoProject/UCO#509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
A follow-on patch will regenerate Make-managed files. References: * ucoProject/UCO#509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
References: * ucoProject/UCO#501 * ucoProject/UCO#509 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
Background
Issue 470 posed a question about what the superclass of
types:Thread
should be within the UCO namespaces. At the time that question was written,core:UcoThing
was being introduced, and was considered the correct answer.core:UcoThing
was being introduced in Issue 430. Between the beginning and ending of that issue, another intermediary class was introduced for a class hierarchy of thoseUcoThing
s that are notUcoObject
s orUcoFacet
s:UcoInherentCharacterizationThing
.The
types:Dictionary
class became a subclass ofcore:UcoInherentCharacterizationThing
, as part of resolving 430. However,types:Thread
, as a "Data structure" ontology class that we have chosen to not introduce into theUcoObject
subclass hierarchy (particularly in discussion on Issue 393 that introducedtypes:Thread
), is not a subclass ofcore:UcoInherentCharacterizationThing
. This appears to have been an implementation oversight during the resolution of 430.Requirements
Requirement 1
OWL classes in UCO being used as "Data structure" classes should exist in the same subclass hierarchy below
core:UcoInherentCharacterizationThing
.Requirement 2
types:Thread
must be moved in the subclass hierarchy to alongside other "Data structure" classes.Risk / Benefit analysis
Benefits
core:Compilation
and its subclass hierarchy.core:Compilation
is analogous toco:Set
but has been around since UCO's beginning as a general, unordered object-aggregation.types:Thread
and other structures that will potentially be imported from the Collections Ontology.Risks
Moving
types:Thread
to be a subclass ofcore:UcoInherentCharacterizationThing
will mean it will no longer be permitted to define a node as, say:kb:some-thing a types:Thread, observable:ObservableObject ; .
This would be a member of two disjoint classes (
UcoObject
andUcoInherentCharacterizationThing
), and thus would be invalid.Nor would it be permitted to define a new class:
(UCO test mechanisms don't currently review this in an automated manner.)
While this appears to capture the design intent of Issue 430, due to 1.0.0 defining
types:Thread
as a subclass of the most-generalUcoThing
, implementing this fix would be a backwards-incompatible change that would have to wait for UCO 2.0.0.Competencies demonstrated
Competency 1
A user is interested in a yet-unexplored usage pattern for
co:List
based on someObservableObject
---let's say representingtraceroute
results---and wonders how to define a new class.Competency Question 1.1
Before the change in this proposal, what looks like an appropriate subclassing, according to
types:Thread
?Result 1.1
ex:IPAddressRoute a owl:Class , sh:NodeShape ; rdfs:subClassOf observable:ObservableObject, co:List ; sh:property [ sh:class observable:IPv4Address ; sh:path ( co:item co:itemContent ) ; ] ; .
(This also breaks from the current UCO design pattern with
Facet
s, which is another of the reasons we chose to moveco:*
subclasses over toUcoInherentCharacterizationThing
.)Competency Question 1.2
With this fix, what is the appropriate design style?
Result 1.2
ex:IPAddressRouteFacet a owl:Class , sh:NodeShape ; rdfs:subClassOf core:Facet ; sh:property [ sh:class co:Thread ; sh:path ex:hasIPv4AddressRoute ; ] , [ rdfs:seeAlso observable:MessageThreadFacet ; sh:class observable:IPv4Address ; sh:path ( ex:hasIPv4AddressRoute co:item co:itemContent ) ; ] ; .
Solution suggestion
types:Thread rdfs:subClassOf core:UcoThing
totypes:Thread rdfs:subClassOf core:UcoInherentCharacterizationThing
.uco-qc.ttl
that fails CI on detecting a class definition that is a subclass of bothuco-core:UcoObject
andco:Collection
. (co:Collection
is the CO topmost class, just underowl:Thing
.)Coordination
develop
for the next releasedevelop
state with backwards-compatible implementation merged intodevelop-2.0.0
develop-2.0.0
The text was updated successfully, but these errors were encountered: