Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
00a6afb
docs: map existing codebase
marvinm2 Mar 6, 2026
986bb2d
docs: initialize project
marvinm2 Mar 6, 2026
70f459b
feat(01-02): add controlled category vocabulary with validation tests
marvinm2 Mar 6, 2026
0f080e0
feat(01-02): add header conventions guide for SPARQL query enrichment
marvinm2 Mar 6, 2026
ba2e860
feat(01-01): add header preservation to CI extraction script
marvinm2 Mar 6, 2026
f67ff41
test(02-01): add header validation test suite for .rq files
marvinm2 Mar 6, 2026
fa84274
docs(02-01): complete header validation test suite plan
marvinm2 Mar 6, 2026
8f06e80
feat(02-02): add title and category headers to A. Metadata queries
marvinm2 Mar 7, 2026
65e6d8f
feat(02-03): add title and category headers to C-F query files
marvinm2 Mar 7, 2026
832399e
feat(02-02): add title and category headers to B. Communities queries
marvinm2 Mar 7, 2026
9b87668
feat(02-03): add title and category headers to G-J query files
marvinm2 Mar 7, 2026
8cf836f
docs(02-02): complete A and B directory header enrichment plan
marvinm2 Mar 7, 2026
b097d89
docs(02-03): complete C-J directory header enrichment plan
marvinm2 Mar 7, 2026
c22c055
test(03-01): add description header presence test and update field order
marvinm2 Mar 8, 2026
807fbac
docs(03-01): complete description header test setup plan
marvinm2 Mar 8, 2026
56af22e
feat(03-02): add description headers to A. Metadata root and datacoun…
marvinm2 Mar 8, 2026
bc23887
feat(03-02): add description headers to A. Metadata datasources and s…
marvinm2 Mar 8, 2026
fa9e83b
feat(03-04): add description headers to D-G query files
marvinm2 Mar 8, 2026
85c9912
feat(03-04): add description headers to H-J query files
marvinm2 Mar 8, 2026
7a9d0b4
docs(03-02): complete A. Metadata description headers plan
marvinm2 Mar 8, 2026
2f50cac
feat(03-03): add description headers to C. Collaborations query files
marvinm2 Mar 8, 2026
327ae9a
docs(03-04): complete D-J description headers plan
marvinm2 Mar 8, 2026
59607ad
docs(03-03): complete B+C description headers plan
marvinm2 Mar 8, 2026
c927c69
feat(04-01): add CI lint script for required header validation
marvinm2 Mar 8, 2026
2f7566a
feat(04-03): add pathway ID parameterization to D. General and H. Che…
marvinm2 Mar 8, 2026
18ad576
docs(04-01): update HEADER_CONVENTIONS.md to mustache placeholder syntax
marvinm2 Mar 8, 2026
0577f6d
feat(04-02): add species parameterization to metadata, datadump, and …
marvinm2 Mar 8, 2026
4431b11
feat(04-03): add pathway and protein ID parameterization to E. Litera…
marvinm2 Mar 8, 2026
beb3f8b
feat(04-02): add species parameterization to Lipids community queries
marvinm2 Mar 8, 2026
fb6c614
docs(04-01): complete CI lint and conventions plan
marvinm2 Mar 8, 2026
b29ede7
docs(04-03): complete pathway and protein ID parameterization plan
marvinm2 Mar 8, 2026
0ead0b3
docs(04-02): complete species parameterization plan
marvinm2 Mar 8, 2026
c42d381
feat: dynamic species autocomplete, lipid class dropdown, collaborati…
marvinm2 Mar 9, 2026
fb2e609
chore: remove .planning/ from tracking and add .gitignore
marvinm2 Mar 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/extractRQs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
run: pip install rdflib
- name: Extract
run: python scripts/transformDotTtlToDotSparql.py
- name: Lint headers
run: python scripts/lint_headers.py

- name: Commit new .rq files
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.planning/
5 changes: 5 additions & 0 deletions A. Metadata/authors.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Authors of All Pathways
# category: Metadata
# description: Lists all pathway authors with their name, homepage, and ORCID,
# along with the number of pathways each author created.

PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX foaf: <http://xmlns.com/foaf/0.1/>

Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/averageDatanodes.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Average Data Nodes per Pathway
# category: Metadata
# description: Calculates the average, minimum, and maximum number of data nodes per
# pathway in WikiPathways.

SELECT (AVG(?no) AS ?avg)
(MIN(?no) AS ?min)
(MAX(?no) AS ?max)
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/averageGeneProducts.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Average Gene Products per Pathway
# category: Metadata
# description: Calculates the average, minimum, and maximum number of gene products
# per pathway in WikiPathways.

SELECT (AVG(?no) AS ?avg)
(MIN(?no) AS ?min)
(MAX(?no) AS ?max)
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/averageInteractions.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Average Interactions per Pathway
# category: Metadata
# description: Calculates the average, minimum, and maximum number of interactions
# per pathway in WikiPathways.

SELECT (AVG(?no) AS ?avg)
(MIN(?no) AS ?min)
(MAX(?no) AS ?max)
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/averageMetabolites.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Average Metabolites per Pathway
# category: Metadata
# description: Calculates the average, minimum, and maximum number of metabolites per
# pathway in WikiPathways.

SELECT (AVG(?no) AS ?avg)
(MIN(?no) AS ?min)
(MAX(?no) AS ?max)
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/averageProteins.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Average Proteins per Pathway
# category: Metadata
# description: Calculates the average, minimum, and maximum number of proteins per
# pathway in WikiPathways.

SELECT (AVG(?no) AS ?avg)
(MIN(?no) AS ?min)
(MAX(?no) AS ?max)
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countDataNodes.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Data Nodes
# category: Metadata
# description: Counts the total number of data nodes in WikiPathways.

SELECT DISTINCT count(?DataNodes) as ?DataNodeCount
WHERE {
?DataNodes a wp:DataNode .
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countGeneProducts.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Gene Products
# category: Metadata
# description: Counts the total number of gene products in WikiPathways.

SELECT DISTINCT count(?geneProduct) as ?GeneProductCount
WHERE {
?geneProduct a wp:GeneProduct .
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countInteractions.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Interactions
# category: Metadata
# description: Counts the total number of interactions in WikiPathways.

SELECT DISTINCT count(?Interaction) as ?InteractionCount
WHERE {
?Interaction a wp:Interaction .
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countMetabolites.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Metabolites
# category: Metadata
# description: Counts the total number of metabolites in WikiPathways.

SELECT DISTINCT count(?Metabolite) as ?MetaboliteCount
WHERE {
?Metabolite a wp:Metabolite .
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Pathways
# category: Metadata
# description: Counts the total number of pathways in WikiPathways.

SELECT DISTINCT count(?Pathway) as ?PathwayCount
WHERE {
?Pathway a wp:Pathway, skos:Collection .
Expand Down
4 changes: 4 additions & 0 deletions A. Metadata/datacounts/countProteins.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Count of Proteins
# category: Metadata
# description: Counts the total number of proteins in WikiPathways.

SELECT DISTINCT count(?protein) as ?ProteinCount
WHERE {
?protein a wp:Protein .
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/countSignalingPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Count of Signaling Pathways
# category: Metadata
# description: Counts the total number of signaling pathways in WikiPathways by
# filtering on the signaling pathway ontology tag.

SELECT count(distinct ?pathway) as ?pathwaycount
WHERE {
?tag1 a owl:Class ;
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/datacounts/linkoutCounts.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: External Linkout Counts
# category: Metadata
# description: Counts the number of distinct entities linked to each external database
# (ChEBI, ChemSpider, HMDB, PubChem, Ensembl, NCBI Gene, HGNC, Rhea, UniProt).

SELECT ?pred (COUNT(DISTINCT ?entity) AS ?count) WHERE {
VALUES ?pred {
# metabolites
Expand Down
5 changes: 4 additions & 1 deletion A. Metadata/datasources/WPforChemSpider.rq
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#List of WikiPathways for ChemSpider identifiers
# title: WikiPathways for ChemSpider Identifiers
# category: Data Sources
# description: Lists pathways containing metabolites with ChemSpider identifiers,
# showing the pathway title and extracted ChemSpider ID.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?csId,36) as ?chemspider) where {
?gene a wp:Metabolite ;
Expand Down
25 changes: 14 additions & 11 deletions A. Metadata/datasources/WPforEnsembl.rq
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#List of WikiPathways for Ensembl identifiers

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?ensId,32) as ?ensembl) where {
?gene a wp:GeneProduct ;
dcterms:identifier ?id ;
dcterms:isPartOf ?pathwayRes ;
wp:bdbEnsembl ?ensId .
?pathwayRes a wp:Pathway ;
dcterms:identifier ?wpid ;
dc:title ?title .
}
# title: WikiPathways for Ensembl Identifiers
# category: Data Sources
# description: Lists pathways containing gene products with Ensembl identifiers,
# showing the pathway title and extracted Ensembl ID.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?ensId,32) as ?ensembl) where {
?gene a wp:GeneProduct ;
dcterms:identifier ?id ;
dcterms:isPartOf ?pathwayRes ;
wp:bdbEnsembl ?ensId .
?pathwayRes a wp:Pathway ;
dcterms:identifier ?wpid ;
dc:title ?title .
}
5 changes: 4 additions & 1 deletion A. Metadata/datasources/WPforHGNC.rq
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#List of WikiPathways for HGNC symbols
# title: WikiPathways for HGNC Symbols
# category: Data Sources
# description: Lists pathways containing gene products with HGNC symbol identifiers,
# showing the pathway title and extracted HGNC symbol.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?hgncId,37) as ?HGNC) where {
?gene a wp:GeneProduct ;
Expand Down
5 changes: 4 additions & 1 deletion A. Metadata/datasources/WPforHMDB.rq
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#ist of WikiPathways for HMDB identifiers
# title: WikiPathways for HMDB Identifiers
# category: Data Sources
# description: Lists pathways containing metabolites with HMDB identifiers, showing
# the pathway title and extracted HMDB ID.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?hmdbId,29) as ?hmdb) where {
?gene a wp:Metabolite ;
Expand Down
5 changes: 4 additions & 1 deletion A. Metadata/datasources/WPforNCBI.rq
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#List of WikiPathways for NCBI Gene identifiers
# title: WikiPathways for NCBI Gene Identifiers
# category: Data Sources
# description: Lists pathways containing gene products with NCBI Gene identifiers,
# showing the pathway title and extracted NCBI Gene ID.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?ncbiGeneId,33) as ?NCBIGene) where {
?gene a wp:GeneProduct ;
Expand Down
25 changes: 14 additions & 11 deletions A. Metadata/datasources/WPforPubChemCID.rq
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#List of WikiPathways for PubChem CID identifiers

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?cid,46) as ?PubChem) where {
?gene a wp:Metabolite ;
dcterms:identifier ?id ;
dcterms:isPartOf ?pathwayRes ;
wp:bdbPubChem ?cid .
?pathwayRes a wp:Pathway ;
dcterms:identifier ?wpid ;
dc:title ?title .
}
# title: WikiPathways for PubChem CID Identifiers
# category: Data Sources
# description: Lists pathways containing metabolites with PubChem compound identifiers,
# showing the pathway title and extracted PubChem CID.

select distinct ?pathwayRes (str(?wpid) as ?pathway) (str(?title) as ?pathwayTitle) (fn:substring(?cid,46) as ?PubChem) where {
?gene a wp:Metabolite ;
dcterms:identifier ?id ;
dcterms:isPartOf ?pathwayRes ;
wp:bdbPubChem ?cid .
?pathwayRes a wp:Pathway ;
dcterms:identifier ?wpid ;
dc:title ?title .
}
5 changes: 5 additions & 0 deletions A. Metadata/linksets.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Linksets Overview
# category: Metadata
# description: Returns all VoID linksets in the WikiPathways RDF with their title,
# creation date, and license information.

SELECT DISTINCT ?dataset (str(?titleLit) as ?title) ?date ?license
WHERE {
?dataset a void:Linkset ;
Expand Down
7 changes: 6 additions & 1 deletion A. Metadata/metadata.rq
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
# title: Dataset Metadata
# category: Metadata
# description: Returns all VoID datasets in the WikiPathways RDF with their title,
# creation date, and license information.

SELECT DISTINCT ?dataset (str(?titleLit) as ?title) ?date ?license
WHERE {
?dataset a void:Dataset ;
dcterms:title ?titleLit ;
dcterms:license ?license ;
pav:createdOn ?date .
}
}
7 changes: 6 additions & 1 deletion A. Metadata/prefixes.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: SPARQL Prefixes
# category: Metadata
# description: Lists all namespace prefixes declared in the WikiPathways SPARQL
# endpoint via SHACL prefix declarations.

PREFIX sh: <http://www.w3.org/ns/shacl#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

Expand All @@ -6,4 +11,4 @@ SELECT ?prefix ?namespace WHERE {
sh:prefix ?prefix ;
sh:namespace ?namespace
] .
}
}
8 changes: 7 additions & 1 deletion A. Metadata/species/PWsforSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
# title: Pathways for a Species
# category: Metadata
# description: Lists all pathways for a given species, returning the WikiPathways
# identifier and page URL. Default species is Mus musculus.
# param: species | string | Homo sapiens | Species

SELECT DISTINCT ?wpIdentifier ?pathway ?page
WHERE {
?pathway dc:title ?title .
?pathway foaf:page ?page .
?pathway dc:identifier ?wpIdentifier .
?pathway wp:organismName "Mus musculus" . #Replace "Mus musculus" with other species: "Homo sapiens", "Rattus norvegicus", "Danio rerio"
?pathway wp:organismName "{{species}}" .
}
ORDER BY ?wpIdentifier
5 changes: 5 additions & 0 deletions A. Metadata/species/countDataNodePerSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Data Nodes per Species
# category: Metadata
# description: Counts the number of distinct data nodes per species in WikiPathways,
# ordered by count descending.

select (count(distinct ?datanode) as ?count) (str(?label) as ?species) where {
?datanode a wp:DataNode ;
dcterms:isPartOf ?pw .
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/species/countGeneProductsPerSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Gene Products per Species
# category: Metadata
# description: Counts the number of distinct gene products per species in WikiPathways,
# ordered by count descending.

select (count(distinct ?gene) as ?count) (str(?label) as ?species) where {
?gene a wp:GeneProduct ;
dcterms:isPartOf ?pw .
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/species/countMetabolitesPerSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Metabolites per Species
# category: Metadata
# description: Counts the number of distinct metabolites per species in WikiPathways,
# ordered by count descending.

select (str(?label) as ?species) (count(distinct ?metabolite) as ?count) where {
?metabolite a wp:Metabolite ;
dcterms:isPartOf ?pw .
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/species/countPathwaysPerSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Pathways per Species
# category: Metadata
# description: Counts the number of pathways per species in WikiPathways, returning
# the species name, organism URI, and pathway count.

SELECT DISTINCT (str(?label) as ?name) ?organism (count(?pw) as ?pathwayCount)
WHERE {
?pw dc:title ?title ;
Expand Down
5 changes: 5 additions & 0 deletions A. Metadata/species/countProteinsPerSpecies.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Proteins per Species
# category: Metadata
# description: Counts the number of distinct proteins per species in WikiPathways,
# ordered by count descending.

select (count(distinct ?protein) as ?count) (str(?label) as ?species) where {
?protein a wp:Protein ;
dcterms:isPartOf ?pw .
Expand Down
6 changes: 5 additions & 1 deletion B. Communities/AOP/allPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: AOP Community Pathways
# category: Communities
# description: Lists all pathways tagged with the AOP community curation tag.

PREFIX wp: <http://vocabularies.wikipathways.org/wp#>
PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX cur: <http://vocabularies.wikipathways.org/wp#Curation:>
Expand All @@ -7,4 +11,4 @@ WHERE {
?pathway wp:ontologyTag cur:AOP ;
a wp:Pathway ;
dc:title ?title .
}
}
4 changes: 4 additions & 0 deletions B. Communities/AOP/allProteins.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: AOP Community Proteins
# category: Communities
# description: Lists all proteins found in AOP community pathways.

SELECT DISTINCT ?pathway (str(?label) as ?Protein)
WHERE {
?pathway wp:ontologyTag cur:AOP ;
Expand Down
4 changes: 4 additions & 0 deletions B. Communities/CIRM Stem Cell Pathways/allPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: CIRM Stem Cell Pathways
# category: Communities
# description: Lists all pathways tagged with the CIRM Stem Cell community curation tag.

SELECT DISTINCT ?pathway (str(?title) as ?PathwayTitle)
WHERE {
?pathway wp:ontologyTag cur:CIRM_Related ;
Expand Down
4 changes: 4 additions & 0 deletions B. Communities/CIRM Stem Cell Pathways/allProteins.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: CIRM Stem Cell Proteins
# category: Communities
# description: Lists all proteins found in CIRM Stem Cell community pathways.

SELECT DISTINCT ?pathway (str(?label) as ?Protein)
WHERE {
?pathway wp:ontologyTag cur:CIRM_Related ;
Expand Down
4 changes: 4 additions & 0 deletions B. Communities/COVID19/allPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: COVID-19 Community Pathways
# category: Communities
# description: Lists all pathways tagged with the COVID-19 community curation tag.

SELECT DISTINCT ?pathway (str(?title) as ?PathwayTitle)
WHERE {
?pathway wp:ontologyTag cur:COVID19 ;
Expand Down
4 changes: 4 additions & 0 deletions B. Communities/COVID19/allProteins.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: COVID-19 Community Proteins
# category: Communities
# description: Lists all proteins found in COVID-19 community pathways.

SELECT DISTINCT ?pathway (str(?label) as ?Protein)
WHERE {
?pathway wp:ontologyTag cur:COVID19 ;
Expand Down
5 changes: 5 additions & 0 deletions B. Communities/Inborn Errors of Metabolism/allMetabolicPWs.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# title: Inborn Errors of Metabolism Metabolic Pathways
# category: Communities
# description: Retrieves pathways classified under metabolic pathway ontology terms,
# filtering by label to find metabolic pathway annotations.

SELECT distinct ?pathway ?label ?tag
WHERE {
?tag1 a owl:Class ;
Expand Down
4 changes: 4 additions & 0 deletions B. Communities/Inborn Errors of Metabolism/allPathways.rq
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# title: Inborn Errors of Metabolism Pathways
# category: Communities
# description: Lists all pathways tagged with the Inborn Errors of Metabolism (IEM) community curation tag.

SELECT DISTINCT ?pathway (str(?title) as ?PathwayTitle)
WHERE {
?pathway wp:ontologyTag cur:IEM ;
Expand Down
Loading