@prefix this: . @prefix sub: . @prefix np: . @prefix grlc: . @prefix dct: . @prefix nt: . @prefix npx: . @prefix xsd: . @prefix rdfs: . @prefix orcid: . @prefix prov: . @prefix foaf: . sub:Head { this: a np:Nanopublication; np:hasAssertion sub:assertion; np:hasProvenance sub:provenance; np:hasPublicationInfo sub:pubinfo . } sub:assertion { sub:get-project-people-institutions a grlc:grlc-query; rdfs:label "Get the people and institutions of a project"; grlc:endpoint ; grlc:sparql """prefix rdfs: prefix np: prefix npa: prefix npx: prefix nt: prefix gen: prefix ff: prefix foaf: select ?relation ?relation_label ?agent ?agent_label ?np (\"^\" as ?np_label) where { values ?_space_multi_iri {} service { select (group_concat(distinct ?mpk; separator=\" \") as ?memberPubkeys) where { graph npa:graph { npa:hasCurrentSpaceState ?stateG . } values ?_space_multi_iri {} graph ?stateG { ?ri a gen:RoleInstantiation ; npa:forSpace ?_space_multi_iri ; npa:forAgent ?memberAgent ; npa:hasRoleType ?rt . filter(?rt in (gen:AdminRole, gen:MaintainerRole, gen:MemberRole)) ?acct a npa:AccountState ; npa:agent ?memberAgent ; npa:pubkey ?mpk . } } } graph npa:graph { ?np npa:hasValidSignatureForPublicKeyHash ?npPubkey . filter not exists { ?invNp npx:invalidates ?np ; npa:hasValidSignatureForPublicKeyHash ?npPubkey . } filter not exists { ?supNp npx:supersedes ?np . } filter not exists { ?np npx:hasNanopubType npx:ExampleNanopub . } ?np np:hasAssertion ?a . ?np np:hasPublicationInfo ?pi . } filter(contains(?memberPubkeys, ?npPubkey)) { # People: one nanopub per role instantiation. graph ?pi { ?np npx:hasNanopubType gen:RoleInstantiation } graph ?a { ?project ?relation ?agent } filter(?relation in (ff:has-principal-investigator, ff:has-project-leader, ff:has-data-steward, ff:has-participant)) optional { graph ?pi { ?agent foaf:name ?agentName } } } union { # Institutions: asserted in each project's own root definition. graph ?a { ?project a gen:Space . ?project ?relation ?agent . } filter(?relation in (ff:has-lead-institution, ff:has-partner-institution, ff:has-funder)) optional { graph ?pi { ?agent rdfs:label ?agentName } } optional { graph ?a { ?project rdfs:label ?projectLabelFromDef } } } filter(?project = ?_space_multi_iri || strstarts(str(?project), concat(str(?_space_multi_iri), \"/\"))) optional { graph ?pi { ?project nt:hasLabelFromApi ?projectLabelFromApi } } bind(coalesce(?projectLabelFromApi, ?projectLabelFromDef, \"\") as ?project_label) bind(coalesce(?agentName, \"\") as ?agent_label) bind(if(?relation = ff:has-principal-investigator, 1, if(?relation = ff:has-project-leader, 2, if(?relation = ff:has-data-steward, 3, if(?relation = ff:has-participant, 4, if(?relation = ff:has-lead-institution, 5, if(?relation = ff:has-partner-institution, 6, 7)))))) as ?relation_order) bind(replace(strafter(str(?relation), \"https://w3id.org/fair/ff/terms/has-\"), \"-\", \" \") as ?relation_label) } order by ?project ?relation_order ?agent_label""" . } 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-08-11T08:46:47Z"^^xsd:dateTime; dct:creator orcid:0000-0002-1267-0234; dct:license ; npx:embeds sub:get-project-people-institutions; rdfs:label "Get the people and institutions of a project"; nt:wasCreatedFromProvenanceTemplate ; nt:wasCreatedFromPubinfoTemplate , ; nt:wasCreatedFromTemplate . sub:sig npx:hasAlgorithm "RSA"; npx:hasPublicKey "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwUtewGCpT5vIfXYE1bmf/Uqu1ojqnWdYxv+ySO80ul8Gu7m8KoyPAwuvaPj0lvPtHrg000qMmkxzKhYknEjq8v7EerxZNYp5B3/3+5ZpuWOYAs78UnQVjbHSmDdmryr4D4VvvNIiUmd0yxci47dTFUj4DvfHnGd6hVe5+goqdcwIDAQAB"; npx:hasSignature "XJqleLmdglNFLcdVpRhJq479Hg9C1uJUF2/yqCUSVIqP+OjgCDEU1DF4bzbigfFEZ35A4WcuZBowJusa0rQf5zn+vxS5TQexSpikq573qWsg26osN8nLxiwAYDsmoUrDeKFPhrpRQohxVsfluEMt9TFaDdad3gA+43tONMU/7zI="; npx:hasSignatureTarget this:; npx:signedBy orcid:0000-0002-1267-0234 . }