Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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: 1 addition & 1 deletion idranges.toml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Sofia Garcia https://orcid.org/0000-0001-2345-6789

# MANDATORY: URL of repository or online vocabulary editor
# repository = "https://github.com/YOUR-ORG/YOUR-REPO"
repository = "https://github.com/NFDI4Cat/vocab-template"
repository = "https://github.com/NFDI4Cat/voc4cat-template"

# Optional: Jinja template for provenance URLs (git blame links)
# Available template variables: entity_id, vocab_name, version, github_repo
Expand Down
8 changes: 4 additions & 4 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ setup:
upgrade:
uv tool install --upgrade voc4cat --with git+https://github.com/dalito/pyLODE.git@nfdi4cat-2.x

# Check the voc4cat.xlsx file in inbox/ for errors
# Check the vocab_example.xlsx file in inbox/ for errors
[group('individual steps')]
check: _fake_actions_env
@voc4cat --version
Expand All @@ -53,7 +53,7 @@ check: _fake_actions_env
[group('individual steps')]
convert: _fake_actions_env
# make a backup of the original file just in case
@cp inbox-excel-vocabs/voc4cat.xlsx inbox-excel-vocabs/voc4cat.xlsx.backup
@cp inbox-excel-vocabs/vocab_example.xlsx inbox-excel-vocabs/vocab_example.xlsx.backup
@voc4cat convert --config _main_branch/idranges.toml --logfile outbox/voc4cat.log --outdir outbox inbox-excel-vocabs/
@if [ -z "$(ls outbox/*.ttl 2>/dev/null)" ]; then \
@echo "No ttl file in outbox. Building joined vocabulary ttl-file from individual ttl-files in vocabulary.\n" && \
Expand All @@ -62,7 +62,7 @@ convert: _fake_actions_env

#=== post-convert checks ===
# Delete xlsx in outbox that may be present from former runs
@rm -f outbox/voc4cat.xlsx
@rm -f outbox/vocab_example.xlsx
# check all ttl file(s) in outbox
@voc4cat check --redundant-hierarchies --config _main_branch/idranges.toml --logfile outbox/voc4cat.log outbox/
# check if vocabulary changes are allowed
Expand All @@ -76,7 +76,7 @@ docs:
# Rebuild the xlsx file from the joined ttl file.
[group('individual steps')]
xlsx:
@rm -f outbox/voc4cat.xlsx
@rm -f outbox/vocab_example.xlsx
@voc4cat convert --config idranges.toml --logfile outbox/voc4cat.log --template templates/default_sheets.xlsx outbox/

# Join individual ttl files in vocabularies/ to one turtle file in outbox/
Expand Down
9 changes: 7 additions & 2 deletions vocabularies/vocab_example/0000001.ttl
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

<https://example.org/test/0000001>
a skos:Concept ;
dcterms:created "2023-08-10"^^xsd:date ;
dcterms:identifier "0000001"^^xsd:token ;
rdfs:isDefinedBy <https://datatracker.ietf.org/doc/html/rfc2396> ;
dcterms:modified "2025-12-27"^^xsd:date ;
dcterms:provenance <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000001.ttl> ;
rdfs:seeAlso <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000001.ttl> ;
skos:altLabel "URI"@en ;
skos:changeNote "0000-0001-2345-6789 Created concept"@en ;
skos:definition "Uniform Resource Identifier is a compact string of characters for identifying an abstract or physical resource."@en ;
skos:historyNote "0000-0001-2345-6789 Created concept"@en ;
skos:inScheme <https://example.org/test/> ;
skos:narrower <https://example.org/test/0000002> ;
skos:prefLabel "Uniform Resource Identifier"@en ;
skos:relatedMatch <https://example.org/test/0000003> ;
skos:topConceptOf <https://example.org/test/> ;
prov:hadPrimarySource <https://datatracker.ietf.org/doc/html/rfc2396> ;
.
9 changes: 7 additions & 2 deletions vocabularies/vocab_example/0000002.ttl
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

<https://example.org/test/0000002>
a skos:Concept ;
dcterms:created "2023-08-10"^^xsd:date ;
dcterms:identifier "0000002"^^xsd:token ;
rdfs:isDefinedBy <https://www.w3.org/TR/2010/NOTE-curie-20101216/> ;
dcterms:modified "2025-12-27"^^xsd:date ;
dcterms:provenance <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000002.ttl> ;
rdfs:seeAlso <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000002.ttl> ;
skos:altLabel
"CURIE"@en ,
"CompactURI"@en ;
skos:broader <https://example.org/test/0000001> ;
skos:changeNote "0000-0001-2345-6789 Created concept"@en ;
skos:definition "A CURIE (or Compact URI) defines a generic, abbreviated syntax for expressing Uniform Resource Identifiers (URIs). "@en ;
skos:historyNote "0000-0001-2345-6789 Created concept"@en ;
skos:inScheme <https://example.org/test/> ;
skos:prefLabel "Compact Universal Resource Locator"@en ;
prov:hadPrimarySource <https://www.w3.org/TR/2010/NOTE-curie-20101216/> ;
.
9 changes: 7 additions & 2 deletions vocabularies/vocab_example/0000003.ttl
Original file line number Diff line number Diff line change
@@ -1,16 +1,21 @@
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

<https://example.org/test/0000003>
a skos:Concept ;
dcterms:created "2023-08-10"^^xsd:date ;
dcterms:identifier "0000003"^^xsd:token ;
rdfs:isDefinedBy <https://datatracker.ietf.org/doc/html/rfc3987> ;
dcterms:modified "2025-12-27"^^xsd:date ;
dcterms:provenance <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000003.ttl> ;
rdfs:seeAlso <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000003.ttl> ;
skos:altLabel "IRI"@en ;
skos:changeNote "0000-0001-2345-6789 Created concept"@en ;
skos:definition "Internationalized Resource Identifier (IRI) is an internet protocol standard which builds on the Uniform Resource Identifier (URI) protocol by greatly expanding the set of permitted characters."@en ;
skos:historyNote "0000-0001-2345-6789 Created concept"@en ;
skos:inScheme <https://example.org/test/> ;
skos:prefLabel "Internationalized Resource Identifier"@en ;
skos:topConceptOf <https://example.org/test/> ;
prov:hadPrimarySource <https://datatracker.ietf.org/doc/html/rfc3987> ;
.
7 changes: 5 additions & 2 deletions vocabularies/vocab_example/0000010.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@ PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

<https://example.org/test/0000010>
a skos:Collection ;
dcterms:created "2023-08-10"^^xsd:date ;
dcterms:identifier "0000010"^^xsd:token ;
dcterms:isPartOf <https://example.org/test/> ;
dcterms:modified "2025-12-27"^^xsd:date ;
dcterms:provenance <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000010.ttl> ;
rdfs:isDefinedBy <https://example.org/test/> ;
rdfs:seeAlso <https://github.com/NFDI4Cat/voc4cat-template/blame/main/vocabularies/vocab_example/0000010.ttl> ;
skos:changeNote "0000-0001-2345-6789 Created collection"@en ;
skos:definition "Collection of terms related to linked data."@en ;
skos:historyNote "0000-0001-2345-6789 Created collection"@en ;
skos:inScheme <https://example.org/test/> ;
skos:member
<https://example.org/test/0000001> ,
Expand Down
34 changes: 27 additions & 7 deletions vocabularies/vocab_example/concept_scheme.ttl
Original file line number Diff line number Diff line change
@@ -1,23 +1,43 @@
PREFIX dcat: <http://www.w3.org/ns/dcat#>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX schema: <https://schema.org/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>

<https://example.org/test/>
a skos:ConceptScheme ;
dcterms:created "2023-03-10"^^xsd:date ;
dcterms:creator <http://example.org/nfdi4cat/> ;
dcterms:hasPart <https://example.org/test/0000010> ;
dcterms:created "2025-01-01"^^xsd:date ;
dcterms:creator
<https://orcid.org/0000-0001-2345-6788> ,
<https://orcid.org/0000-0001-2345-6789> ;
dcterms:identifier ""^^xsd:token ;
dcterms:modified "2023-03-10"^^xsd:date ;
dcterms:modified "2025-12-27"^^xsd:date ;
dcterms:publisher <http://example.org/nfdi4cat/> ;
owl:versionInfo "v2023-03-10" ;
skos:definition "A test vocabulary for the voc4cat template"@en ;
skos:definition "Description of the vocabulary"@en ;
skos:hasTopConcept
<https://example.org/test/0000001> ,
<https://example.org/test/0000003> ;
skos:historyNote "https://orcid.org/0000-0001-2345-6789 Sofia Garcia"@en ;
skos:prefLabel "Test-of-Voc4Cat"@en ;
skos:historyNote "Created 2025-01-01."@en ;
skos:prefLabel "My Vocabulary"@en ;
dcat:contactPoint "Sofia Garcia (orcid:0000-0001-2345-6789)" ;
.

<http://example.org/nfdi4cat/>
a schema:Organization ;
schema:name "http://example.org/nfdi4cat/" ;
schema:url "http://example.org/nfdi4cat/"^^xsd:anyURI ;
.

<https://orcid.org/0000-0001-2345-6788>
a schema:Person ;
schema:name "Alice Smith" ;
schema:url "https://orcid.org/0000-0001-2345-6788"^^xsd:anyURI ;
.

<https://orcid.org/0000-0001-2345-6789>
a schema:Person ;
schema:name "Sofia Garcia" ;
schema:url "https://orcid.org/0000-0001-2345-6789"^^xsd:anyURI ;
.
Loading