Nanopublication

< Home

ID

https://w3id.org/np/RAE47ty6qDLpysySankxy37Bn5RBT273lKcIbTtAdDtQo

Formats

.trig | .trig.txt | .jelly | .jelly.txt | .jsonld | .jsonld.txt | .nq | .nq.txt | .xml | .xml.txt

Content

@prefix this: <https://w3id.org/np/RAE47ty6qDLpysySankxy37Bn5RBT273lKcIbTtAdDtQo> .
@prefix sub: <https://w3id.org/np/RAE47ty6qDLpysySankxy37Bn5RBT273lKcIbTtAdDtQo/> .
@prefix np: <http://www.nanopub.org/nschema#> .
@prefix dct: <http://purl.org/dc/terms/> .
@prefix nt: <https://w3id.org/np/o/ntemplate/> .
@prefix npx: <http://purl.org/nanopub/x/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix orcid: <https://orcid.org/> .
@prefix prov: <http://www.w3.org/ns/prov#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .

sub:Head {
  this: a np:Nanopublication;
    np:hasAssertion sub:assertion;
    np:hasProvenance sub:provenance;
    np:hasPublicationInfo sub:pubinfo .
}

sub:assertion {
  sub:get-space-info a <https://w3id.org/kpxl/grlc/grlc-query>;
    dct:description "Returns basic key-value facts about a given space (type, alternative IDs, start and end date for time-limited spaces, and the root-definition nanopub), taken from its latest non-invalidated space-declaration nanopub signed by an admin of the space. Each property and value is rendered as a link to its defining IRI where applicable, and properties such as the type and the alternative IDs can carry multiple values. Alternative IDs are shown as their full URL, trimmed in the middle with an ellipsis beyond 80 characters. Both columns use the '_noheader' convention so the redundant header row is dropped.";
    dct:license <http://www.apache.org/licenses/LICENSE-2.0>;
    rdfs:label "Get space info";
    <https://w3id.org/kpxl/grlc/endpoint> <https://w3id.org/np/l/nanopub-query-1.1/repo/full>;
    <https://w3id.org/kpxl/grlc/sparql> """prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
prefix dct: <http://purl.org/dc/terms/>
prefix np: <http://www.nanopub.org/nschema#>
prefix npa: <http://purl.org/nanopub/admin/>
prefix npx: <http://purl.org/nanopub/x/>
prefix schema: <http://schema.org/>
prefix owl: <http://www.w3.org/2002/07/owl#>
prefix gen: <https://w3id.org/kpxl/gen/terms/>

select distinct ?Property_noheader ?Property_label ?Value_noheader ?Value_label where {
  values ?_space_multi_iri {}
  service <https://w3id.org/np/l/nanopub-query-1.1/repo/spaces> {
    graph npa:graph { npa:thisRepo npa:hasCurrentSpaceState ?stateG . }
    graph ?stateG {
      ?ri a gen:RoleInstantiation ; npa:inverseProperty gen:hasAdmin ; npa:forSpace ?_space_multi_iri ; npa:forAgent ?admin .
      ?acct a npa:AccountState ; npa:agent ?admin ; npa:pubkey ?pubkey .
    }
  }
  graph npa:graph {
    ?np npa:hasValidSignatureForPublicKeyHash ?pubkey .
    filter not exists { ?npx npx:invalidates ?np ; npa:hasValidSignatureForPublicKeyHash ?pubkey . }
    ?np np:hasAssertion ?a .
  }
  graph ?a { ?_space_multi_iri a gen:Space . }
  optional { graph ?a { ?_space_multi_iri a ?typeIri . filter(?typeIri != gen:Space) } }
  optional { graph ?a { ?_space_multi_iri owl:sameAs ?altVal } }
  optional { graph ?a { ?_space_multi_iri schema:startDate ?startVal } }
  optional { graph ?a { ?_space_multi_iri schema:endDate ?endVal } }
  bind(strlen(str(?altVal)) as ?altLen)
  bind(if(?altLen > 80, concat(substr(str(?altVal), 1, 38), '...', substr(str(?altVal), ?altLen - 37)), str(?altVal)) as ?altDisp)
  bind(concat('<a href=', '\"', str(?altVal), '\"', '>', ?altDisp, '</a>') as ?altAnchor)
  values (?key ?Property_noheader ?Property_label) {
    ('Type' rdf:type 'Type:')
    ('Alternative IDs' owl:sameAs 'Alternative IDs:')
    ('Start date' schema:startDate 'Start date:')
    ('End date' schema:endDate 'End date:')
    ('Root definition' gen:hasRootDefinition 'Root definition:')
  }
  bind(if(?key='Type', ?typeIri, if(?key='Alternative IDs', ?altAnchor, if(?key='Start date', str(?startVal), if(?key='End date', str(?endVal), ?np)))) as ?Value_noheader)
  filter(bound(?Value_noheader))
  bind(if(?key='Type', replace(str(?typeIri), '^.*[/#]', ''), if(?key='Root definition', substr(strafter(str(?np), '/np/'), 1, 10), '')) as ?Value_label)
}
order by (if(?key='Type', 1, if(?key='Alternative IDs', 2, if(?key='Start date', 3, if(?key='End date', 4, 5)))))""" .
}

sub:provenance {
  sub:assertion prov:wasAttributedTo orcid:0000-0002-1267-0234 .
}

sub:pubinfo {
  orcid:0000-0002-1267-0234 foaf:name "Tobias Kuhn" .
  
  this: dct:created "2026-06-15T07:28:57Z"^^xsd:dateTime;
    dct:creator orcid:0000-0002-1267-0234;
    dct:license <https://creativecommons.org/licenses/by/4.0/>;
    npx:embeds sub:get-space-info;
    npx:supersedes <https://w3id.org/np/RAR6y-G2b_AEfUA6UN4TP1dTzrOiSonHFuSnwo2LBqJ8c>;
    rdfs:label "Get space info";
    nt:wasCreatedFromProvenanceTemplate <https://w3id.org/np/RA7lSq6MuK_TIC6JMSHvLtee3lpLoZDOqLJCLXevnrPoU>;
    nt:wasCreatedFromPubinfoTemplate <https://w3id.org/np/RA0J4vUn_dekg-U1kK3AOEt02p9mT2WO03uGxLDec1jLw>,
      <https://w3id.org/np/RAoTD7udB2KtUuOuAe74tJi1t3VzK0DyWS7rYVAq1GRvw>, <https://w3id.org/np/RAukAcWHRDlkqxk7H2XNSegc1WnHI569INvNr-xdptDGI>;
    nt:wasCreatedFromTemplate <https://w3id.org/np/RAEFAt-QcFK0ZhqfvlsmS10BnzGJA0xwOICZXkO-ai87k> .
  
  sub:sig npx:hasAlgorithm "RSA";
    npx:hasPublicKey "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwUtewGCpT5vIfXYE1bmf/Uqu1ojqnWdYxv+ySO80ul8Gu7m8KoyPAwuvaPj0lvPtHrg000qMmkxzKhYknEjq8v7EerxZNYp5B3/3+5ZpuWOYAs78UnQVjbHSmDdmryr4D4VvvNIiUmd0yxci47dTFUj4DvfHnGd6hVe5+goqdcwIDAQAB";
    npx:hasSignature "pMcmgp91NyV77sI5XyuLMNrUfstl5KGqgiSsWQaIs3KgOPnQ/320KvzB2QmiDHjndmv6/BEzBJOQWZCv0y3zep1xDgFAP5WxLDb3PHzVc3Vi9qm5j4P91ctyfg+xipUbE3oo5JlHzMpfWpLxKBrNagJ7G6qgkA4fMJKGYy6aLpo=";
    npx:hasSignatureTarget this:;
    npx:signedBy orcid:0000-0002-1267-0234 .
}