@prefix dc: .
@prefix this: .
@prefix sub: .
@prefix np: .
@prefix nt: .
@prefix npx: .
@prefix xsd: .
@prefix rdfs: .
@prefix orcid: .
@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-instances-simple dc:description "This query returns the instances assigned to the given class.";
dc:license ;
a ;
rdfs:label "Get instances for class (simple result)";
;
"""prefix dct:
prefix rdfs:
prefix np:
prefix npa:
prefix npx:
prefix nt:
select ?instance ?instance_label ?date ?creator ?np where {
graph ?g {
?instance a ?_class_iri .
}
graph npa:graph {
?np npa:hasValidSignatureForPublicKey ?pubkey .
filter not exists { ?npx npx:invalidates ?np ; npa:hasValidSignatureForPublicKey ?pubkey . }
?np npa:hasGraph ?g .
?np np:hasPublicationInfo ?i .
?np dct:created ?date .
optional { ?np npx:signedBy ?creator }
}
optional { graph ?g { ?instance rdfs:label ?instanceLabel1 . } }
optional { graph ?g { ?instance dct:title ?instanceLabel2 . } }
optional { graph ?i { ?instance rdfs:label ?instanceLabel3 . } }
optional { graph ?i { ?instance nt:hasLabelFromApi ?instanceLabel4 . } }
bind(coalesce(?instanceLabel1, ?instanceLabel2, ?instanceLabel3, ?instanceLabel4) as ?instance_label)
}""" .
}
sub:provenance {
sub:assertion prov:wasAttributedTo orcid:0000-0002-1267-0234 .
}
sub:pubinfo {
orcid:0000-0002-1267-0234 foaf:name "Tobias Kuhn" .
this: dc:created "2025-11-27T12:26:25.113Z"^^xsd:dateTime;
dc:creator orcid:0000-0002-1267-0234;
dc:license ;
npx:embeds sub:get-instances-simple;
npx:wasCreatedAt ;
prov:wasDerivedFrom ;
nt:wasCreatedFromProvenanceTemplate ;
nt:wasCreatedFromPubinfoTemplate ,
, ;
nt:wasCreatedFromTemplate .
sub:sig npx:hasAlgorithm "RSA";
npx:hasPublicKey "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQD4Wj537OijfOWVtsHMznuXKISqBhtGDQZfdO6pbb4hg9EHMcUFGTLbWaPrP783PHv8HMAAPjvEkHLaOHMIknqhaIa5236lfBO3r+ljVdYBElBcLvROmwG+ZGtmPNZf7lMhI15xf5TfoaSa84AFRd5J2EXekK6PhaFQhRm1IpSYtwIDAQAB";
npx:hasSignature "oWgJc38mEAgB/UIaRrPtmOsj/rxOvVEKm7Egh6wLcuFQUSIGz1U1i/M2JM4jUs3Jxpyt6prG0G6R9E1xVxULu3Q8x+mehGBl5w91TAoj/7iBDK5xPYYARnJm0OOmM+UlFCg5s4xPz19V10WYhArYInT+cQx6VsTEA61ObDQq8fk=";
npx:hasSignatureTarget this:;
npx:signedBy orcid:0000-0002-1267-0234 .
}