@prefix this: . @prefix sub: . @prefix np: . @prefix dct: . @prefix nt: . @prefix npx: . @prefix xsd: . @prefix rdfs: . @prefix orcid: . @prefix ns1: . @prefix prov: . @prefix foaf: . sub:Head { this: np:hasAssertion sub:assertion; np:hasProvenance sub:provenance; np:hasPublicationInfo sub:pubinfo; a np:Nanopublication . } sub:assertion { sub:get-newer-versions-of-np dct:description "This query returns all newer versions of a given nanopublication, including those that since have been superseded or retracted."; dct:license ; a ; rdfs:label "Get all newer versions of this nanopublication"; ; """prefix np: prefix npa: prefix npx: prefix dct: select ?newerVersion ?date ?retractedBy ?supersededBy where { graph npa:graph { ?_np_iri npa:hasValidSignatureForPublicKey ?pubkey . ?newerVersion npa:hasValidSignatureForPublicKey ?pubkey . ?newerVersion dct:created ?date . optional { ?retractedBy npx:retracts ?newerVersion ; npa:hasValidSignatureForPublicKey ?pubkey . } optional { ?supersededBy npx:supersedes ?newerVersion ; npa:hasValidSignatureForPublicKey ?pubkey . } } graph npa:networkGraph { ?newerVersion (npx:supersedes)* ?_np_iri . } } order by desc(?date) ?newerVersion""" . } sub:provenance { sub:assertion prov:wasAttributedTo orcid:0000-0002-1267-0234 . } sub:pubinfo { orcid:0000-0002-1267-0234 foaf:name "Tobias Kuhn" . sub:sig npx:hasAlgorithm "RSA"; npx:hasPublicKey "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQD4Wj537OijfOWVtsHMznuXKISqBhtGDQZfdO6pbb4hg9EHMcUFGTLbWaPrP783PHv8HMAAPjvEkHLaOHMIknqhaIa5236lfBO3r+ljVdYBElBcLvROmwG+ZGtmPNZf7lMhI15xf5TfoaSa84AFRd5J2EXekK6PhaFQhRm1IpSYtwIDAQAB"; npx:hasSignature "UQh5/xpilUJCWJs2ggGbKMQy6+1pyMubTrr4Dg+flQjoxYP3NJvDEVLmTwtOrei8iVhfS95UBhEGfhxRaSsd0Cje4kNzuIeqlAbZVm8BXOuxZdpsMznH44L6bJwfxnNZfPxTvjNCBb7fVoe8EQPaWWZ8WxhF4FTYwJPhmAcJc60="; npx:hasSignatureTarget this:; npx:signedBy orcid:0000-0002-1267-0234 . this: dct:created "2025-01-28T11:56:37.047Z"^^xsd:dateTime; dct:creator orcid:0000-0002-1267-0234; dct:license ; npx:introduces sub:get-newer-versions-of-np; npx:supersedes ; npx:wasCreatedAt ; nt:wasCreatedFromProvenanceTemplate ns1:RANwQa4ICWS5SOjw7gp99nBpXBasapwtZF1fIM3H2gYTM; nt:wasCreatedFromPubinfoTemplate , , ; nt:wasCreatedFromTemplate . }