rows { options { physical_type: PHYSICAL_STREAM_TYPE_QUADS max_name_table_size: 128 max_prefix_table_size: 16 max_datatype_table_size: 16 logical_type: LOGICAL_STREAM_TYPE_DATASETS version: 2 } } rows { prefix { value: "https://w3id.org/np/" } } rows { name { value: "RAF1X7AZlesaHCSnLcMoA6UgQRj9Sxa-Fu_L64rGPHDKg" } } rows { namespace { name: "this" value { prefix_id: 1 } } } rows { prefix { value: "https://w3id.org/np/RAF1X7AZlesaHCSnLcMoA6UgQRj9Sxa-Fu_L64rGPHDKg/" } } rows { name { } } rows { namespace { name: "sub" value { prefix_id: 2 } } } rows { prefix { value: "http://www.nanopub.org/nschema#" } } rows { namespace { name: "np" value { prefix_id: 3 name_id: 2 } } } rows { prefix { value: "https://w3id.org/kpxl/grlc/" } } rows { namespace { name: "grlc" value { prefix_id: 4 name_id: 2 } } } rows { prefix { value: "http://purl.org/dc/terms/" } } rows { namespace { name: "dct" value { prefix_id: 5 name_id: 2 } } } rows { prefix { value: "https://w3id.org/np/o/ntemplate/" } } rows { namespace { name: "nt" value { prefix_id: 6 name_id: 2 } } } rows { prefix { value: "http://purl.org/nanopub/x/" } } rows { namespace { name: "npx" value { prefix_id: 7 name_id: 2 } } } rows { prefix { value: "http://www.w3.org/2001/XMLSchema#" } } rows { namespace { name: "xsd" value { prefix_id: 8 name_id: 2 } } } rows { prefix { value: "http://www.w3.org/2000/01/rdf-schema#" } } rows { namespace { name: "rdfs" value { prefix_id: 9 name_id: 2 } } } rows { prefix { value: "https://orcid.org/" } } rows { namespace { name: "orcid" value { prefix_id: 10 name_id: 2 } } } rows { prefix { value: "http://www.w3.org/ns/prov#" } } rows { namespace { name: "prov" value { prefix_id: 11 name_id: 2 } } } rows { prefix { value: "http://xmlns.com/foaf/0.1/" } } rows { namespace { name: "foaf" value { prefix_id: 12 name_id: 2 } } } rows { name { value: "hasAssertion" } } rows { name { value: "assertion" } } rows { name { value: "Head" } } rows { quad { s_iri { prefix_id: 1 name_id: 1 } p_iri { prefix_id: 3 name_id: 3 } o_iri { prefix_id: 2 } g_iri { } } } rows { name { value: "hasProvenance" } } rows { name { value: "provenance" } } rows { quad { p_iri { prefix_id: 3 } o_iri { prefix_id: 2 } } } rows { name { value: "hasPublicationInfo" } } rows { name { value: "pubinfo" } } rows { quad { p_iri { prefix_id: 3 } o_iri { prefix_id: 2 } } } rows { prefix { value: "http://www.w3.org/1999/02/22-rdf-syntax-ns#" } } rows { name { value: "type" } } rows { name { value: "Nanopublication" } } rows { quad { p_iri { prefix_id: 13 } o_iri { prefix_id: 3 } } } rows { name { value: "get-replies" } } rows { name { value: "description" } } rows { quad { s_iri { prefix_id: 2 } p_iri { prefix_id: 5 } o_literal { lex: "This query returns the whole reply thread below a given discourse contribution, following the Nanoarguments model: not only the contributions that reply directly to it, but also the replies to those replies, and so on to any depth. Replies are found through as:inReplyTo chains, which are followed across nanopublications; a reply that targets a whole nanopublication instead of the contribution node inside it is followed as well, so threads that mix both conventions stay connected. Each row gives the nesting level (1 for a direct reply), the text of the reply, the CiTO stance it takes toward its target where it declares one, the contribution it replies to, and its author and date. Rows are ordered so that each direct reply is followed by its own sub-thread, oldest first, and the text is prefixed with an arrow marker per nesting level. Retracted and superseded nanopublications are excluded; example nanopublications are kept, since they are part of the thread they were published into." } g_iri { prefix_id: 2 name_id: 4 } } } rows { name { value: "license" } } rows { prefix { value: "http://www.apache.org/licenses/" } } rows { name { value: "LICENSE-2.0" } } rows { quad { p_iri { prefix_id: 5 name_id: 14 } o_iri { prefix_id: 14 } } } rows { name { value: "grlc-query" } } rows { quad { p_iri { prefix_id: 13 name_id: 10 } o_iri { prefix_id: 4 name_id: 16 } } } rows { name { value: "label" } } rows { quad { p_iri { prefix_id: 9 } o_literal { lex: "Get replies to a discourse contribution" } } } rows { name { value: "endpoint" } } rows { prefix { value: "https://w3id.org/np/l/nanopub-query-1.1/repo/" } } rows { name { value: "full" } } rows { quad { p_iri { prefix_id: 4 } o_iri { prefix_id: 15 } } } rows { name { value: "sparql" } } rows { quad { p_iri { prefix_id: 4 } o_literal { lex: "prefix rdf: \nprefix rdfs: \nprefix dct: \nprefix np: \nprefix npa: \nprefix npx: \nprefix prov: \nprefix foaf: \nprefix as: \n\nselect ?level ?reply ?reply_label ?stance ?in_reply_to ?in_reply_to_label ?by ?by_label ?date ?reply_target ?np ?np_label\nwhere {\n {\n select ?st ?np ?created ?by ?parentnode\n (coalesce(min(?value), min(?stlabel), str(?st)) as ?text)\n (min(?stancelabel) as ?stance)\n (coalesce(min(?parentvalue), min(?parentlabel), str(?parentnode)) as ?parenttext)\n (coalesce(min(?byname), str(?by)) as ?byfull)\n where {\n { values ?_resource_multi_iri {}\n ?st (as:inReplyTo|np:hasAssertion)+ ?_resource_multi_iri }\n union\n { values ?_resource_multi_iri {}\n graph npa:graph { ?rootnp npx:introduces ?_resource_multi_iri }\n ?st (as:inReplyTo|np:hasAssertion)+ ?rootnp }\n graph npa:graph {\n ?np np:hasAssertion ?a ; np:hasProvenance ?prov ; np:hasPublicationInfo ?pi ;\n npa:hasValidSignatureForPublicKeyHash ?pubkey ; dct:created ?created .\n filter not exists {\n ?npi npx:invalidates ?np ; npa:hasValidSignatureForPublicKeyHash ?pubkey .\n }\n }\n graph ?a { ?st as:inReplyTo ?parent }\n optional { graph ?a { ?st rdf:value ?value } }\n optional { graph ?a { ?st rdfs:label ?stlabel } }\n optional {\n graph ?a { ?st ?stancep ?parent }\n filter(strstarts(str(?stancep), \"http://purl.org/spar/cito/\"))\n bind(lcase(replace(strafter(str(?stancep), \"http://purl.org/spar/cito/\"), \"([a-z])([A-Z])\", \"$1 $2\")) as ?stancelabel)\n }\n optional { graph ?prov { ?a prov:wasAttributedTo ?by } }\n optional { graph ?pi { ?by foaf:name ?byname } }\n optional { graph npa:graph { ?parent np:hasAssertion ?parentassertion } }\n bind(coalesce(?parentassertion, ?parent) as ?parentnode)\n optional {\n graph npa:graph {\n ?parentnp np:hasAssertion ?parentg ; npa:hasValidSignatureForPublicKeyHash ?parentkey .\n filter not exists {\n ?parentnpi npx:invalidates ?parentnp ; npa:hasValidSignatureForPublicKeyHash ?parentkey .\n }\n }\n graph ?parentg { ?parentnode rdf:value ?parentvalue }\n }\n optional {\n graph npa:graph {\n ?parentnp2 np:hasAssertion ?parentg2 ; npa:hasValidSignatureForPublicKeyHash ?parentkey2 .\n filter not exists {\n ?parentnpi2 npx:invalidates ?parentnp2 ; npa:hasValidSignatureForPublicKeyHash ?parentkey2 .\n }\n }\n graph ?parentg2 { ?parentnode rdfs:label ?parentlabel }\n }\n }\n group by ?st ?np ?created ?by ?parentnode\n }\n {\n select (str(?lst) as ?lkey) (count(distinct ?lanc) as ?level) (min(?lancdate) as ?sortkey) where {\n { values ?_resource_multi_iri {}\n ?lanc (as:inReplyTo|np:hasAssertion)+ ?_resource_multi_iri }\n union\n { values ?_resource_multi_iri {}\n graph npa:graph { ?lrootnp npx:introduces ?_resource_multi_iri }\n ?lanc (as:inReplyTo|np:hasAssertion)+ ?lrootnp }\n ?lst (as:inReplyTo|np:hasAssertion)* ?lanc .\n graph npa:graph { ?lancnp np:hasAssertion ?lancg ; dct:created ?lancdate }\n graph ?lancg { ?lanc as:inReplyTo ?lancparent }\n }\n group by ?lst\n }\n filter(str(?st) = ?lkey)\n bind(?st as ?reply)\n bind(concat(if(?level = 1, \"\", if(?level = 2, \"\342\206\263 \", if(?level = 3, \"\342\206\263\342\206\263 \", if(?level = 4, \"\342\206\263\342\206\263\342\206\263 \", \"\342\206\263\342\206\263\342\206\263\342\206\263 \")))), ?text) as ?reply_label)\n bind(?parentnode as ?in_reply_to)\n bind(if(strlen(?parenttext) > 70, concat(substr(?parenttext, 1, 70), \"\342\200\246\"), ?parenttext) as ?in_reply_to_label)\n bind(?byfull as ?by_label)\n bind(substr(str(?created), 1, 10) as ?date)\n bind(str(?st) as ?reply_target)\n bind(\"^\" as ?np_label)\n}\norder by ?sortkey ?date ?reply_label" } } } rows { name { value: "wasAttributedTo" } } rows { name { value: "0000-0002-1267-0234" } } rows { quad { s_iri { prefix_id: 2 name_id: 4 } p_iri { prefix_id: 11 name_id: 21 } o_iri { prefix_id: 10 } g_iri { prefix_id: 2 name_id: 7 } } } rows { name { value: "name" } } rows { quad { s_iri { prefix_id: 10 name_id: 22 } p_iri { prefix_id: 12 } o_literal { lex: "Tobias Kuhn" } g_iri { prefix_id: 2 name_id: 9 } } } rows { name { value: "created" } } rows { datatype { value: "http://www.w3.org/2001/XMLSchema#dateTime" } } rows { quad { s_iri { prefix_id: 1 name_id: 1 } p_iri { prefix_id: 5 name_id: 24 } o_literal { lex: "2026-08-28T09:48:03Z" datatype: 1 } } } rows { name { value: "creator" } } rows { quad { p_iri { } o_iri { prefix_id: 10 name_id: 22 } } } rows { prefix { value: "https://creativecommons.org/licenses/by/4.0/" } } rows { quad { p_iri { prefix_id: 5 name_id: 14 } o_iri { prefix_id: 16 name_id: 2 } } } rows { name { value: "embeds" } } rows { quad { p_iri { prefix_id: 7 name_id: 26 } o_iri { prefix_id: 2 name_id: 12 } } } rows { quad { p_iri { prefix_id: 9 name_id: 17 } o_literal { lex: "Get replies to a discourse contribution" } } } rows { name { value: "wasCreatedFromProvenanceTemplate" } } rows { name { value: "RA7lSq6MuK_TIC6JMSHvLtee3lpLoZDOqLJCLXevnrPoU" } } rows { quad { p_iri { prefix_id: 6 name_id: 27 } o_iri { prefix_id: 1 } } } rows { name { value: "wasCreatedFromPubinfoTemplate" } } rows { name { value: "RACJ58Gvyn91LqCKIO9zu1eijDQIeEff28iyDrJgjSJF8" } } rows { quad { p_iri { prefix_id: 6 } o_iri { prefix_id: 1 } } } rows { name { value: "RAoTD7udB2KtUuOuAe74tJi1t3VzK0DyWS7rYVAq1GRvw" } } rows { quad { o_iri { } } } rows { name { value: "RAukAcWHRDlkqxk7H2XNSegc1WnHI569INvNr-xdptDGI" } } rows { quad { o_iri { } } } rows { name { value: "wasCreatedFromTemplate" } } rows { name { value: "RAEFAt-QcFK0ZhqfvlsmS10BnzGJA0xwOICZXkO-ai87k" } } rows { quad { p_iri { prefix_id: 6 } o_iri { prefix_id: 1 } } } rows { name { value: "sig" } } rows { name { value: "hasAlgorithm" } } rows { quad { s_iri { prefix_id: 2 } p_iri { prefix_id: 7 } o_literal { lex: "RSA" } } } rows { name { value: "hasPublicKey" } } rows { quad { p_iri { } o_literal { lex: "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCwUtewGCpT5vIfXYE1bmf/Uqu1ojqnWdYxv+ySO80ul8Gu7m8KoyPAwuvaPj0lvPtHrg000qMmkxzKhYknEjq8v7EerxZNYp5B3/3+5ZpuWOYAs78UnQVjbHSmDdmryr4D4VvvNIiUmd0yxci47dTFUj4DvfHnGd6hVe5+goqdcwIDAQAB" } } } rows { name { value: "hasSignature" } } rows { quad { p_iri { } o_literal { lex: "HB3nR2eXKchH2T3giig0BovLkual/U+tKQwHxrFDAspDz2Zt2ougjeRiq8dkWTKIE76DMNFlylCn7GDdqmNcQQDZy6Q7UKQ7pxSV9/0tjDPf87QkshUZSkuSLeB7d4OFeSZJeABjxa2ycwBpmiYZ/OFkdo8O3/s+uHRMv12otF4=" } } } rows { name { value: "hasSignatureTarget" } } rows { quad { p_iri { } o_iri { prefix_id: 1 name_id: 1 } } } rows { name { value: "signedBy" } } rows { quad { p_iri { prefix_id: 7 name_id: 40 } o_iri { prefix_id: 10 name_id: 22 } } }