Skip to content

Commit

Permalink
Fixed examples for catalogs
Browse files Browse the repository at this point in the history
  • Loading branch information
fellahst committed Feb 8, 2024
1 parent af07a05 commit ca9e3d7
Show file tree
Hide file tree
Showing 29 changed files with 369 additions and 195 deletions.
86 changes: 49 additions & 37 deletions docs/examples/catalog/catalog.jsonld
Original file line number Diff line number Diff line change
@@ -1,57 +1,69 @@
{
"@context": "https://raw.githubusercontent.com/DOI-DO/dcat-us/main/context/dcat-us-3.0.jsonld",
"@graph": [
{
"@id": "https://data.census.gov/data/345",
"@type": "dcat:Dataset"
},
{
"@id": "https://census.gov",
"@type": "foaf:Organization"
},
{
"@id": "https://data.census.gov/index.html",
"@type": "foaf:Document"
},
{
"@id": "https://data.census.gov/data/123",
"@type": "dcat:Dataset"
},
{
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"title": "US Census Open Data Catalog",
"description": "US Census Data Catalog",
"issued": {
"@type": "http://www.w3.org/2001/XMLSchema#date",
"@value": "2020-05-25"
},
"language": [
"en"
],
"license": "https://creativecommons.org/publicdomain/zero/1.0/",
"modified": {
"@type": "http://www.w3.org/2001/XMLSchema#date",
"@value": "2020-05-25"
},
"publisher": "https://census.gov",
"title": "US Census Open Data Catalog",
"dataset": [
"https://data.census.gov/data/123",
"https://data.census.gov/data/345"
],
"service": [
"https://data.census.gov/service/123",
"https://data.census.gov/service/345"
"https://data.census.gov/service/service1",
"https://data.census.gov/service2"
],
"homepage": "https://census.gov/catalog.html"
"homepage": "https://census.gov/catalog.html",
"issued": "2020-05-25",
"license": "https://creativecommons.org/publicdomain/zero/1.0/",
"modified": "2020-05-25",
"language": "http://id.loc.gov/vocabulary/iso639-1/en"
},
{
"@id": "https://data.census.gov/service/345",
"@type": "dcat:DataService"
"@id": "https://data.census.gov/data/123",
"@type": "dcat:Dataset",
"title": "Dataset 123",
"description": "This dataset contains information about...",
"publisher": "https://census.gov"
},
{
"@id": "https://data.census.gov/data/345",
"@type": "dcat:Dataset",
"title": "Dataset 345",
"description": "This dataset contains information about...",
"publisher": "https://census.gov"
},
{
"@id": "https://data.census.gov/service/service1",
"@type": "dcat:DataService",
"title": "Data Service 1",
"description": "This is a service that provides data.",
"publisher": "https://example.com/publisher1",
"endpointURL": "https://example.com/service1/endpoint1",
"contactPoint": "http://census.gov/contact"
},
{
"@id": "https://data.census.gov/service2",
"@type": "dcat:DataService",
"title": "Data Service 2",
"description": "This is another service that provides data.",
"publisher": "https://example.com/publisher1",
"endpointURL": "https://example.com/service1/endpoint2",
"contactPoint": "http://census.gov/contact"
},
{
"@id": "https://census.gov",
"@type": "foaf:Organization",
"name": "US Census Bureau",
"prefLabel": "US Census Bureau"
},
{
"@id": "https://data.census.gov/service/123",
"@type": "dcat:DataService"
"@id": "http://census.gov/contact",
"@type": "vcard:Kind",
"fn": "US Census Info",
"hasEmail": "mailto:[email protected]"
}
]
}
}
57 changes: 44 additions & 13 deletions docs/examples/catalog/catalog.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix vcard: <http://www.w3.org/2006/vcard/ns#> .

# ---------- class Catalog --------------------------------------------------
<https://data.census.gov/catalog>
Expand All @@ -11,10 +13,10 @@
dcterms:title "US Census Open Data Catalog" ;
dcterms:description "US Census Data Catalog" ;
dcterms:publisher <https://census.gov> ;

dcat:dataset <https://data.census.gov/data/123>, <https://data.census.gov/data/345> ;

# recommended properties
dcat:dataset <https://data.census.gov/data/123>, <https://data.census.gov/data/345> ;

foaf:homepage <https://census.gov/catalog.html> ;
dcat:service <https://data.census.gov/service/123>, <https://data.census.gov/service/345> ;
dcterms:issued "2020-05-25"^^xsd:date ;
Expand All @@ -28,22 +30,51 @@

# ---------- class Dataset --------------------------------------------------
<https://data.census.gov/data/123>
a dcat:Dataset .

a dcat:Dataset ;
dcterms:title "Dataset 123" ;
dcterms:description "This dataset contains information about..." ;
dcterms:publisher <https://census.gov> ;
.
<https://data.census.gov/data/345>
a dcat:Dataset .

# ---------- class Document --------------------------------------------------
<https://data.census.gov/index.html>
a foaf:Document .
a dcat:Dataset ;
dcterms:title "Dataset 345" ;
dcterms:description "This dataset contains information about..." ;
dcterms:publisher <https://census.gov> ;
.

# ---------- class DataService -----------------------------------------------
<https://data.census.gov/service/123>
a dcat:DataService .
<https://data.census.gov/service/service1>
a dcat:DataService ;
dcterms:title "Data Service 1" ;
dcterms:description "This is a service that provides data." ;
dcterms:publisher <https://example.com/publisher1> ;
dcat:endpointURL <https://example.com/service1/endpoint1> ;
dcat:contactPoint <http://census.gov/contact>;
.


<https://data.census.gov/service2>
a dcat:DataService ;

dcterms:title "Data Service 2" ;
dcterms:description "This is another service that provides data." ;
dcterms:publisher <https://example.com/publisher1> ;
dcat:endpointURL <https://example.com/service1/endpoint2> ;
dcat:contactPoint <http://census.gov/contact>;
.

<https://data.census.gov/service/345>
a dcat:DataService .

# ---------- class Agent -----------------------------------------------------
<https://census.gov>
a foaf:Organization .
a foaf:Organization ;
foaf:name "US Census Bureau" ;
skos:prefLabel "US Census Bureau" ;
.

<http://census.gov/contact>
a vcard:Kind ;
vcard:fn "US Census Info" ;
vcard:hasEmail <mailto:[email protected]>
.

9 changes: 8 additions & 1 deletion docs/examples/catalog/conforms-to.jsonld
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,12 @@
"@context": "https://raw.githubusercontent.com/DOI-DO/dcat-us/main/context/dcat-us-3.0.jsonld",
"@id": "https://census.gov/Catalog1",
"@type": "dcat:Catalog",
"title": "US Census Open Data Catalog",
"description": "US Census Data Catalog",
"publisher": "https://census.gov",
"dataset": [
"https://census.gov/Dataset1",
"https://census.gov/Dataset2"
],
"conformsTo": "http://resource.data.gov/profile/dcat-us#"
}
}
7 changes: 7 additions & 0 deletions docs/examples/catalog/conforms-to.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,12 @@

<https://census.gov/Catalog1>
a dcat:Catalog ;
# mandatory properties
dcterms:title "US Census Open Data Catalog" ;
dcterms:description "US Census Data Catalog" ;
dcterms:publisher <https://census.gov> ;
dcat:dataset <https://census.gov/Dataset1> , <https://census.gov/Dataset2> ;

# Catalog conforms to the DCAT-US profile
dcterms:conformsTo <http://resource.data.gov/profile/dcat-us#> ;
.
19 changes: 14 additions & 5 deletions docs/examples/catalog/dataset.jsonld
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,27 @@
{
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"title": "US Census Open Data Catalog",
"description": "US Census Data Catalog",
"publisher": "https://census.gov",
"dataset": [
"https://data.census.gov/data/123",
"https://data.census.gov/data/345"
]
},
{
"@id": "https://data.census.gov/data/345",
"@type": "dcat:Dataset"
"@id": "https://data.census.gov/data/123",
"@type": "dcat:Dataset",
"title": "Dataset 123",
"description": "This dataset contains information about...",
"publisher": "https://census.gov"
},
{
"@id": "https://data.census.gov/data/123",
"@type": "dcat:Dataset"
"@id": "https://data.census.gov/data/345",
"@type": "dcat:Dataset",
"title": "Dataset 345",
"description": "This dataset contains information about...",
"publisher": "https://census.gov"
}
]
}
}
25 changes: 12 additions & 13 deletions docs/examples/catalog/dataset.ttl
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@
@prefix dcat: <http://www.w3.org/ns/dcat#> .
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# ---------- class Catalog --------------------------------------------------
<https://data.census.gov/catalog>
a dcat:Catalog ;

# recommended property
dcat:dataset <https://data.census.gov/data/123>,
<https://data.census.gov/data/345> .



# ---------- class Dataset --------------------------------------------------
<https://data.census.gov/data/123>
a dcat:Dataset .

<https://data.census.gov/data/345>
a dcat:Dataset .

# mandatory properties
dcterms:title "US Census Open Data Catalog" ;
# default description of the catalog in english
dcterms:description "US Census Data Catalog",
#Spanish translation of description
"Catálogo de datos abiertos del censo de EE. UU."@es ;
dcterms:publisher <https://census.gov> ;
dcat:dataset <https://data.census.gov/data/123>, <https://data.census.gov/data/345> ;
.
14 changes: 11 additions & 3 deletions docs/examples/catalog/description.jsonld
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
"@context": "https://raw.githubusercontent.com/DOI-DO/dcat-us/main/context/dcat-us-3.0.jsonld",
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"description": "US Census Data Catalog",
"title": "US Census Open Data Catalog"
}
"title": "US Census Open Data Catalog",
"description": "US Census Open Data Catalog",
"descriptionMap": {
"es": "Catálogo de Datos Abiertos del Censo de EE. UU."
},
"publisher": "https://census.gov",
"dataset": [
"https://data.census.gov/data/123",
"https://data.census.gov/data/345"
]
}
11 changes: 8 additions & 3 deletions docs/examples/catalog/description.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@
# ---------- class Catalog --------------------------------------------------
<https://data.census.gov/catalog>
a dcat:Catalog ;

# mandatory properties
dcterms:title "US Census Open Data Catalog" ;
dcterms:description "US Census Data Catalog" .

# description in multiple languages
dcterms:description "US Census Open Data Catalog" ,
"Catálogo de Datos Abiertos del Censo de EE. UU."@es;

dcterms:publisher <https://census.gov> ;
dcat:dataset <https://data.census.gov/data/123>, <https://data.census.gov/data/345> ;
.
23 changes: 11 additions & 12 deletions docs/examples/catalog/homepage.jsonld
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
{
"@context": "https://raw.githubusercontent.com/DOI-DO/dcat-us/main/context/dcat-us-3.0.jsonld",
"@graph": [
{
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"homepage": "https://census.gov/catalog.html"
},
{
"@id": "https://census.gov/catalog.html",
"@type": "foaf:Document"
}
]
}
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"title": "US Census Open Data Catalog",
"description": "US Census Data Catalog",
"publisher": "https://census.gov",
"dataset": [
"https://data.census.gov/data/123",
"https://data.census.gov/data/345"
],
"homepage": "https://census.gov/catalog.html"
}
10 changes: 7 additions & 3 deletions docs/examples/catalog/homepage.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@
# ---------- class Catalog --------------------------------------------------
<https://data.census.gov/catalog>
a dcat:Catalog ;
# recommended property
# mandatory properties
dcterms:title "US Census Open Data Catalog" ;
dcterms:description "US Census Data Catalog" ;
dcterms:publisher <https://census.gov> ;
dcat:dataset <https://data.census.gov/data/123>, <https://data.census.gov/data/345> ;

# Homepage of the catalog
foaf:homepage <https://census.gov/catalog.html> .


<https://census.gov/catalog.html> a foaf:Document.
15 changes: 11 additions & 4 deletions docs/examples/catalog/issued.jsonld
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,15 @@
"@context": "https://raw.githubusercontent.com/DOI-DO/dcat-us/main/context/dcat-us-3.0.jsonld",
"@id": "https://data.census.gov/catalog",
"@type": "dcat:Catalog",
"issued": {
"@type": "http://www.w3.org/2001/XMLSchema#date",
"@value": "2020-05-25"
"title": "US Census Open Data Catalog",
"description": "US Census Data Catalog",
"publisher": "https://census.gov",
"dataset": [
"https://data.census.gov/data/123",
"https://data.census.gov/data/345"
],
"issued": {
"@value" :"2020-05-25",
"@type": "xsd:date"
}
}
}
Loading

0 comments on commit ca9e3d7

Please sign in to comment.