-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path06_06_tissueGetProteins.ttl
128 lines (120 loc) · 5.03 KB
/
06_06_tissueGetProteins.ttl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
@base <http://www.openphacts.org/api> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix dcterms: <http://purl.org/dc/terms/>.
@prefix api: <http://purl.org/linked-data/api/vocab#> .
@prefix void: <http://rdfs.org/ns/void#> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix ops: <http://www.openphacts.org/api#> .
@prefix uniprot: <http://purl.uniprot.org/core/> .
@prefix obo: <http://purl.obolibrary.org/obo/> .
@prefix oboowl: <http://www.geneontology.org/formats/oboInOwl#> .
@prefix nci: <http://ncicb.nci.nih.gov/xml/owl/EVS/Thesaurus.owl#> .
@prefix bfo: <http://purl.obolibrary.org/obo/#> .
@prefix so: <http://purl.org/obo/owl/SO#> .
@prefix nx: <http://www.nextprot.org#> .
@prefix wi: <http://purl.org/ontology/wi/core#> .
@prefix ns: <http://www.nanopub.org/nschema#> .
@prefix obo-rel: <http://purl.org/obo/owl/OBO_REL#> .
@prefix prv: <http://purl.org/net/provenance/ns#> .
@prefix prov: <http://www.w3.org/ns/prov#> .
@prefix ops-terms: <http://www.openphacts.org/terms#> .
<#tissue> a api:API ;
rdfs:label "Tissue"@en ;
api:sparqlEndpoint <http://alpha.openphacts.org:8890/sparql/> ;
api:contentNegotiation api:parameterBased ;
api:variable <#input> ;
api:variable wi:evidence ;
api:variable obo-rel:has_quality ;
api:dataset <http://rdf.imim.es> ;
api:vocabulary <http://ncicb.nci.nih.gov/xml/owl/EVS/Thesaurus.owl#> ;
api:vocabulary <http://semanticscience.org/resource/> ;
api:description "An API configuration to return information about tissues" ;
api:endpoint <#tissueGetProteinsListEndpoint>.
<#tissueGetProteinsListEndpoint> a api:ListEndpoint ;
api:name "[PREVIEW] Proteins for Tissue: List" ;
api:description "A page of items corresponding to assertions that a protein is expressed in a given tissue.";
api:variable <http://www.conceptwiki.org/concept/UUID-neXtProtGold> ;
api:variable <http://www.conceptwiki.org/concept/UUID-neXtProtSilver> ;
api:uriTemplate "/tissue/getProteins?uri={uri}" ;
api:itemTemplate "{uri}" ;
api:exampleRequestPath "/tissue/getProteins?uri=ftp%3A%2F%2Fftp.nextprot.org%2Fpub%2Fcurrent_release%2Fcontrolled_vocabularies%2Fcaloha.obo%23TS-0016" ;
api:selector [
api:where
"GRAPH ?item {
?nextprot_uri bfo:BFO_0000066 ?ops_item ;
obo-rel:has_quality ?quality .
}
?nanopub ns:hasAssertion ?item ;
ns:hasProvenance ?prov .
GRAPH ?prov {
?item a ?evidence_type ;
prv:usedData ?data_used ;
wi:evidence ?evidence_qual_uri ;
prov:wasDerivedFrom ?derived_from ;
prov:wasGeneratedBy ?generated_by .
?evidence_qual_uri rdfs:label ?evidence_qual_label .
}
GRAPH <http://www.nextprot.org/caloha> {
?ops_item rdfs:label ?tissue_label .
}"
] ;
api:viewer <#tissueListViewer> ;
api:defaultViewer <#tissueListViewer> .
<http://www.conceptwiki.org/concept/UUID-neXtProtGold> api:name "gold" .
<http://www.conceptwiki.org/concept/UUID-neXtProtSilver> api:name "silver" .
<#input> api:name "uri" ;
api:label "uri";
api:value "A tissue URI. e.g.: ftp://ftp.nextprot.org/pub/current_release/controlled_vocabularies/caloha.obo#TS-0016" ;
rdfs:range rdfs:Resource .
wi:evidence api:name "evidence" ;
api:label "evidence" ;
api:value "'gold' or 'silver'" ;
api:filterVariable "?item" ;
a rdf:Property .
obo-rel:has_quality api:name "quality" ;
api:label "quality" ;
api:value "One of: none, moderate, high, low, medium, negative, positive, strong, weak." ;
api:filterVariable "?nextprot_uri" ;
a rdf:Property .
<#tissueListViewer> a api:Viewer ;
api:name "tissueListViewer" ;
api:template
"?item ops-terms:tissue ?ops_item ;
ops-terms:protein ?nextprot_uri ;
obo-rel:has_quality ?quality ;
a ?evidence_type ;
prv:usedData ?data_used ;
wi:evidence ?evidence_qual_uri ;
prov:wasDerivedFrom ?derived_from ;
prov:wasGeneratedBy ?generated_by ;
void:inDataset <http://www.nextprot.org> .
?nextprot_uri skos:exactMatch ?uniprot_target .
?uniprot_target void:inDataset <http://purl.uniprot.org> .
?ops_item rdfs:label ?tissue_label ;
void:inDataset <http://www.nextprot.org/caloha> .
?evidence_qual_uri rdfs:label ?evidence_qual_label ;
void:inDataset <http://www.nextprot.org> .
";
api:where
"GRAPH ?item {
?nextprot_uri bfo:BFO_0000066 ?ops_item ;
obo-rel:has_quality ?quality .
}
?nanopub ns:hasAssertion ?item ;
ns:hasProvenance ?prov .
GRAPH ?prov {
?item a ?evidence_type ;
prv:usedData ?data_used ;
wi:evidence ?evidence_qual_uri ;
prov:wasDerivedFrom ?derived_from ;
prov:wasGeneratedBy ?generated_by .
?evidence_qual_uri rdfs:label ?evidence_qual_label .
}
GRAPH <http://www.nextprot.org/caloha> {
?ops_item rdfs:label ?tissue_label .
}
BIND(IRI(CONCAT('http://purl.uniprot.org/uniprot/',STRAFTER(STR(?nextprot_uri),'http://www.nextprot.org/db/search#NX_'))) AS ?uniprot_target)" .