. . . . "This query returns the sub-classes of the given class, restricted to sub-classes that are part of the same space and published by admins, maintainers, or members of that space. Each sub-class appears exactly once, taken from its winning definition: the newest non-invalidated nanopublication signed by a member+ of the maintaining space that describes the sub-class as part of the same resource. That resolution matters because an override records only prov:wasDerivedFrom and never npx:supersedes, so nothing is invalidated and every version of a term stays live -- without it a sub-class is listed once per version. Judging on the winner also makes the listing follow later edits: a version that drops the rdfs:subClassOf triple removes the row, and a version that adds gen:WithdrawnTerm hides the sub-class, while publishing a newer version without that type reinstates it." . . . "Get sub-classes for class (from space members)" . . "prefix owl: \nprefix dct: \nprefix rdfs: \nprefix np: \nprefix npa: \nprefix npx: \nprefix nt: \nprefix gen: \n\nselect ?subclass (coalesce(min(?untaggedLabel), min(?anyLabel)) as ?subclass_label) ?date ?np where {\n # the resource/ontology that the given (parent) class belongs to\n graph ?pg { ?_class_iri dct:isPartOf ?resource . }\n # collect the public keys of admins, maintainers, and members of the space maintaining that resource\n service {\n select ?resource (group_concat(?mpk; separator=\" \") as ?memberPubkeys) where {\n graph npa:graph { npa:thisRepo npa:hasCurrentSpaceState ?stateG . }\n graph ?stateG {\n ?resource npa:isMaintainedBy? ?space .\n ?ri a gen:RoleInstantiation ; npa:forSpace ?space ; npa:forAgent ?agent ; npa:hasRoleType ?rt .\n filter(?rt in (gen:AdminRole, gen:MaintainerRole, gen:MemberRole))\n ?acct a npa:AccountState ; npa:agent ?agent ; npa:pubkey ?mpk .\n }\n } group by ?resource\n }\n # sub-classes of the given class, that are part of the same resource and signed by a space member\n graph ?g {\n ?subclass rdfs:subClassOf ?_class_iri .\n ?subclass dct:isPartOf ?resource .\n }\n graph npa:graph {\n ?np npa:hasValidSignatureForPublicKeyHash ?pubkey .\n filter not exists { ?npx npx:invalidates ?np ; npa:hasValidSignatureForPublicKeyHash ?pubkey . }\n ?np npa:hasGraph ?g .\n ?np np:hasPublicationInfo ?i .\n ?np dct:created ?date .\n }\n filter(contains(?memberPubkeys, ?pubkey))\n # Keep only the winning definition of each sub-class: the newest live member-signed\n # nanopub describing it as part of this resource. Without this, an override -- which\n # records prov:wasDerivedFrom but never npx:supersedes, so nothing is invalidated --\n # leaves every version live and the sub-class is listed once per version. Judging on\n # the winner also means a version that drops the rdfs:subClassOf triple removes the\n # row, and a withdrawal can be undone by publishing a newer version without the type.\n filter not exists {\n graph ?g2 { ?subclass dct:isPartOf ?resource . }\n graph npa:graph {\n ?np2 npa:hasValidSignatureForPublicKeyHash ?pubkey2 .\n filter not exists { ?np2x npx:invalidates ?np2 ; npa:hasValidSignatureForPublicKeyHash ?pubkey2 . }\n ?np2 npa:hasGraph ?g2 .\n ?np2 dct:created ?date2 .\n }\n filter(contains(?memberPubkeys, ?pubkey2))\n filter(?date2 > ?date || (?date2 = ?date && str(?np2) > str(?np)))\n }\n # a sub-class withdrawn from the resource is not listed\n filter not exists { graph ?g { ?subclass a gen:WithdrawnTerm } }\n optional { graph ?g { ?subclass rdfs:label ?subclassLabel1 . } }\n optional { graph ?g { ?subclass dct:title ?subclassLabel2 . } }\n optional { graph ?i { ?subclass rdfs:label ?subclassLabel3 . } }\n optional { graph ?i { ?subclass nt:hasLabelFromApi ?subclassLabel4 . } }\n bind(coalesce(?subclassLabel1, ?subclassLabel2, ?subclassLabel3, ?subclassLabel4) as ?anyLabel)\n bind(if(lang(?anyLabel) = \"\", ?anyLabel, ?noLabel) as ?untaggedLabel)\n}\ngroup by ?subclass ?date ?np\norder by desc(?date)" . . "Tobias Kuhn" . "2026-08-12T09:26:52Z"^^ . . . . . "Get sub-classes for class (from space members)" . . . . . . . "RSA" . "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwUtewGCpT5vIfXYE1bmf/Uqu1ojqnWdYxv+ySO80ul8Gu7m8KoyPAwuvaPj0lvPtHrg000qMmkxzKhYknEjq8v7EerxZNYp5B3/3+5ZpuWOYAs78UnQVjbHSmDdmryr4D4VvvNIiUmd0yxci47dTFUj4DvfHnGd6hVe5+goqdcwIDAQAB" . "WfrrO3QCpZeqRrGlBF89hEvs1vcIdVza9x1XmFP8SLv3lIdp3m/h1Qu+UT27QWQ4trTQDmcBXo476B4xOCuzCkTf+BbypJIxLdJGMJ6Vyctc/RFu2TDiUvAaHWzOsIbpl3nKFNrc2A1ByDL/pa+EN6T5XCxPN4DYGkHkFtDn+PY=" . . .