Skip to content

Commit

Permalink
Ensure standard semweb prefixes are not uppercases, see #70
Browse files Browse the repository at this point in the history
  • Loading branch information
cmungall committed Apr 14, 2024
1 parent da9a2e6 commit b38747b
Show file tree
Hide file tree
Showing 13 changed files with 54,449 additions and 53,300 deletions.
631 changes: 314 additions & 317 deletions poetry.lock

Large diffs are not rendered by default.

199 changes: 192 additions & 7 deletions src/prefixmaps/data/bioregistry.csv

Large diffs are not rendered by default.

199 changes: 192 additions & 7 deletions src/prefixmaps/data/bioregistry.upper.csv

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/prefixmaps/data/go.csv
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ go,EMAPA,http://purl.obolibrary.org/obo/EMAPA_,canonical
go,ENSEMBL,http://identifiers.org/ensembl/,canonical
go,FB,http://identifiers.org/flybase/,canonical
go,FBbt,http://purl.obolibrary.org/obo/FBbt_,canonical
go,FBdv,http://purl.obolibrary.org/obo/FBdv_,canonical
go,FMA,http://purl.obolibrary.org/obo/FMA_,canonical
go,FYPO,http://purl.obolibrary.org/obo/FYPO_,canonical
go,GeneDB,http://identifiers.org/genedb/,canonical
Expand Down
2 changes: 2 additions & 0 deletions src/prefixmaps/data/linked_data.csv
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ linkml,pav,http://purl.org/pav/,canonical
linkml,prov,http://www.w3.org/ns/prov#,canonical
linkml,qb,http://purl.org/linked-data/cube#,canonical
linkml,qudt,http://qudt.org/schema/qudt/,canonical
linkml,rdf,http://www.w3.org/1999/02/22-rdf-syntax-ns#,canonical
linkml,rdfs,http://www.w3.org/2000/01/rdf-schema#,canonical
linkml,schema,http://schema.org/,canonical
linkml,sh,http://www.w3.org/ns/shacl#,canonical
linkml,shex,http://www.w3.org/ns/shex#,canonical
Expand Down
4 changes: 4 additions & 0 deletions src/prefixmaps/data/linked_data.curated.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
name: linkml
prefixes:
rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
rdfs: http://www.w3.org/2000/01/rdf-schema#
linkml: https://w3id.org/linkml/
dcterms: http://purl.org/dc/terms/
skos: http://www.w3.org/2004/02/skos/core#
Expand All @@ -21,3 +23,5 @@ prefixes:
shex: http://www.w3.org/ns/shex#
biolink: https://w3id.org/biolink/vocab/
foaf: http://xmlns.com/foaf/0.1/


33,514 changes: 16,867 additions & 16,647 deletions src/prefixmaps/data/merged.csv

Large diffs are not rendered by default.

33,514 changes: 16,867 additions & 16,647 deletions src/prefixmaps/data/merged.monarch.csv

Large diffs are not rendered by default.

33,514 changes: 16,867 additions & 16,647 deletions src/prefixmaps/data/merged.oak.csv

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions src/prefixmaps/data/obo.csv
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ obo,FOBI,http://purl.obolibrary.org/obo/FOBI_,canonical
obo,FOODON,http://purl.obolibrary.org/obo/FOODON_,canonical
obo,FOVT,http://purl.obolibrary.org/obo/FOVT_,canonical
obo,FYPO,http://purl.obolibrary.org/obo/FYPO_,canonical
obo,GALLONT,http://purl.obolibrary.org/obo/GALLONT_,canonical
obo,GAZ,http://purl.obolibrary.org/obo/GAZ_,canonical
obo,GECKO,http://purl.obolibrary.org/obo/GECKO_,canonical
obo,GENEPIO,http://purl.obolibrary.org/obo/GENEPIO_,canonical
Expand Down Expand Up @@ -215,6 +216,7 @@ obo,SCDO,http://purl.obolibrary.org/obo/SCDO_,canonical
obo,SEP,http://purl.obolibrary.org/obo/SEP_,canonical
obo,SEPIO,http://purl.obolibrary.org/obo/SEPIO_,canonical
obo,SIBO,http://purl.obolibrary.org/obo/SIBO_,canonical
obo,SLSO,http://purl.obolibrary.org/obo/SLSO_,canonical
obo,SO,http://purl.obolibrary.org/obo/SO_,canonical
obo,SOPHARM,http://purl.obolibrary.org/obo/SOPHARM_,canonical
obo,SPD,http://purl.obolibrary.org/obo/SPD_,canonical
Expand Down
6,117 changes: 3,090 additions & 3,027 deletions src/prefixmaps/data/prefixcc.csv

Large diffs are not rendered by default.

48 changes: 48 additions & 0 deletions src/prefixmaps/data/w3id.csv

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion src/prefixmaps/ingest/ingest_bioregistry.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def from_bioregistry(upper=False, canonical_idorg=True, filter_dubious=True) ->
original namespaces. This can be disabled with ``canonical_idorg=False``.
:param upper: if True, normalize prefix to uppercase
unless a preferred form is stated
unless a preferred form is stated, or it's in the SemWeb collection
:param canonical_idorg: use the original/canonical identifiers.org PURLs
:param filter_dubious: skip namespaces that do not match
strict namespace regular expression
Expand All @@ -71,6 +71,8 @@ def from_bioregistry(upper=False, canonical_idorg=True, filter_dubious=True) ->
uri_prefix_priority=priority, prefix_priority=prefix_priority
)
for record in tqdm(converter.records):
# TODO: auto-set preferred to lowercase for SemWeb collection
# See https://github.com/linkml/prefixmaps/issues/70
if record.prefix in SKIP:
continue
if filter_dubious and not NAMESPACE_RE.match(record.uri_prefix):
Expand Down

0 comments on commit b38747b

Please sign in to comment.