diff --git a/static/ao/config.yml b/static/ao/config.yml
deleted file mode 100644
index 6dab6de..0000000
--- a/static/ao/config.yml
+++ /dev/null
@@ -1,76 +0,0 @@
-name: AO
-stages:
- - name: "Events"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/events-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/events-generator.rq
- - name: "Makers"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/makers-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/makers-generator.rq
- - name: "ObjectDates"
- iterator:
- batchSize: 10000
- delay: 500ms
- #endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- #endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/services/virtuoso/sparql
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/services/jena/sparql
- query: file://static/ao/objectDates-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/objectDates-generator.rq
- - name: "ObjectImages"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/objectImages-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/objectImages-generator.rq
- - name: "ObjectLocations"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/objectLocations-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/objectLocations-generator.rq
- - name: "ObjectLocationDates"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/objectLocationDates-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/objectLocationDates-generator.rq
- - name: "Objects"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/objects-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/objects-generator.rq
- - name: "Sites"
- iterator:
- batchSize: 10000
- delay: 500ms
- endpoint: https://api.demo.triplydb.com/datasets/projects/colonial-heritage/sparql
- query: file://static/ao/sites-iterator.rq
- generator:
- - batchSize: 1000
- query: file://static/ao/sites-generator.rq
diff --git a/static/ao/events-generator.rq b/static/ao/events-generator.rq
deleted file mode 100644
index f461f8d..0000000
--- a/static/ao/events-generator.rq
+++ /dev/null
@@ -1,105 +0,0 @@
-prefix aat:
-prefix dct:
-prefix crm:
-prefix histEvents:
-prefix rdfs:
-construct {
- ?histEventID a crm:E5_Event.
- #histEventID
- ?histEventID crm:P1_is_identified_by _:histEventID.
- _:histEventID a crm:E42_Identifier;
- crm:P2_has_type aat:300404626;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?oldobject.
- #EventName
- ?histEventID crm:P1_is_identified_by _:eventName.
- _:eventName a crm:E42_Identifier;
- crm:P2_has_type aat:300404650;
- rdfs:label "Event name";
- crm:P190_has_symbolic_content ?eventName.
- #EventType
- ?histEventID crm:P67i_is_referred_to_by _:eventType.
- _:eventType a crm:E33_Linguistic_Object;
- rdfs:label "Event type";
- crm:P190_has_symbolic_content ?eventType;
- crm:P1_is_identified_by _:eventTypeD.
- #EventTypeID
- _:eventTypeID a crm:E42_Identifier;
- crm:P2_has_type aat:300404626;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?eventTypeID.
- #IsPublic (should only be created when IsPublic is equal to "1")
- ?histEventID dct:accessRights ?bnIsTrue.
- ?bnIsTrue a dct:RightsStatement;
- rdfs:label "Yes, for public use".
- #DateBegin and DateEnd are not empty
- ?histEventID crm:P4_has_time-span ?timeSpan.
- ?timeSpan a crm:E52_Time-Span;
- rdfs:label "DateBegin and DateEnd";
- crm:P82a_begin_of_the_begin ?dateBegin;
- crm:P82b_end_of_the_end ?dateEnd.
- #DateBegin is empty and DateEnd is not empty
- ?histEventID crm:P4_has_time-span ?dateBeginEmpty.
- ?dateBeginEmpty a crm:E52_Time-Span;
- rdfs:label "DateEnd";
- crm:P82b_end_of_the_end ?dateEnd.
- #DateBegin is not empty and DateEnd is empty
- ?histEventID crm:P4_has_time-span ?dateEndEmpty.
- ?dateEndEmpty a crm:E52_Time-Span;
- rdfs:label "DateBegin";
- crm:P82b_end_of_the_end ?dateBegin.
- #Description - check if description is empty or not
- ?histEventID crm:P67i_is_referred_to_by ?descriptionBlankNode.
- ?descriptionBlankNode a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435416;
- rdfs:label "Description";
- crm:P190_has_symbolic_content ?description.
- # SubTitle - check if SubTitle is empty or not
- ?histEventID crm:P3_has_note ?subtitles.
-}
-where {
- graph {
- # $this histEvents:histEventID ?oldobject.
- bind(iri(concat(str(), str(?oldobject))) as ?histEventID).
- $this histEvents:EventName ?eventName.
- $this histEvents:EventType ?eventType.
- $this histEvents:EventTypeID ?eventTypeID.
- $this histEvents:PublicAccess ?isPublic.
- optional {
- filter(?isPublic = "1")
- bind(bnode() as ?bnIsTrue).
- }
- # DateBegin and DateEnd are not empty
- optional {
- $this histEvents:DateBegin ?dateBegin.
- $this histEvents:DateEnd ?dateEnd.
- bind(bnode() as ?timeSpan)
- }
- # DateBegin is empty and DateEnd is not empty
- optional {
- $this histEvents:DateEnd ?dateEnd.
- filter not exists {
- $this histEvents:DateBegin ?dateBegin.
- }
- bind(bnode() as ?dateBeginEmpty)
- }
- # DateBegin is not empty and DateEnd is empty
- optional {
- $this histEvents:DateBegin ?dateBegin.
- filter not exists {
- $this histEvents:DateEnd ?dateEnd.
- }
- $this histEvents:DateBegin ?dateBegin.
- bind(bnode() as ?dateEndEmpty)
- }
- # Description - check if description is empty or not
- optional {
- $this histEvents:Description ?description.
- bind(bnode() as ?descriptionBlankNode).
- }
- # SubTitle - check if SubTitle is empty or not
- optional {
- $this histEvents:SubTitle ?subtitles.
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/events-iterator.rq b/static/ao/events-iterator.rq
deleted file mode 100644
index 6c1cb61..0000000
--- a/static/ao/events-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix histEvents:
-select * where {
- $this histEvents:HistEventID ?oldobject.
-}
\ No newline at end of file
diff --git a/static/ao/makers-generator.rq b/static/ao/makers-generator.rq
deleted file mode 100644
index 60955ab..0000000
--- a/static/ao/makers-generator.rq
+++ /dev/null
@@ -1,157 +0,0 @@
-prefix aat:
-prefix dct:
-prefix crm:
-prefix crmdig:
-prefix la:
-prefix makerPerson:
-prefix rdfs:
-construct {
- ?_constituentID a crm:E21_Person.
- #constituentID
- ?_constituentID crm:P1_is_identified_by _:_number.
- _:_number a crm:E42_Identifier;
- crm:P2_has_type aat:300404626;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?constituentID.
- ?_constituentID rdfs:label ?displayName.
- ?_constituentID crm:P2_has_type aat:300386174.
- aat:300386174 a crm:E55_Type;
- rdfs:label "Maker".
- ?_constituentID crm:P1_is_identified_by ?_alphaSort.
- ?_alphaSort a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404650;
- rdfs:label "lastname firstname";
- crm:P190_has_symbolic_content ?alphaSort.
- aat:300404650 a crm:E55_Type;
- rdfs:label "Primary Name".
- ?_constituentID crm:P1_is_identified_by _:_name.
- _:_name a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404650;
- rdfs:label "details of the name";
- crm:P190_has_symbolic_content ?displayName.
- ?_name crm:P106_is_composed_of ?_firstName.
- ?_name crm:P106_is_composed_of ?_middleName.
- ?_name crm:P106_is_composed_of ?_lastName.
- ?_name crm:P106_is_composed_of ?_nameTitle.
- ?_name crm:P106_is_composed_of ?_suffix.
- ?_name crm:P67i_is_referred_to_by ?_salutation.
- ?_firstName a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404651;
- rdfs:label "first name";
- crm:P190_has_symbolic_content ?firstName.
- ?_middleName a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404654;
- rdfs:label "middle name";
- crm:P190_has_symbolic_content ?middleName.
- ?_lastName a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404652;
- rdfs:label "last name";
- crm:P190_has_symbolic_content ?lastName.
- ?_nameTitle a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404845;
- rdfs:label "name title";
- crm:P190_has_symbolic_content ?nameTitle.
- ?_suffix a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300404662;
- rdfs:label "suffix";
- crm:P190_has_symbolic_content ?suffix.
- ?_salutation a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300055147;
- rdfs:label "Gender";
- crm:P190_has_symbolic_content ?salutation.
- ?_constituentID la:member_of ?_institution.
- ?_institution a crm:E74_Group;
- rdfs:label "Institution".
- ?_constituentID crm:P67i_is_referred_to_by ?_biography.
- ?_biography a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435422;
- rdfs:label "Biography";
- crm:P190_has_symbolic_content ?biography.
- ?_constituentID crm:P67i_is_referred_to_by ?_nationality.
- ?_nationality a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300379842;
- rdfs:label "Nationality";
- crm:P190_has_symbolic_content ?nationality.
- ?_constituentID crm:P67i_is_referred_to_by ?_school.
- ?_school a crm:E33_Linguistic_Object;
- rdfs:label "School of thought or artistic practice";
- crm:P190_has_symbolic_content ?school.
- ?_constituentID crm:P67i_is_referred_to_by ?_remarks.
- ?_remarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Remarks";
- crm:P190_has_symbolic_content ?remarks.
- ?_constituentID crm:P67i_is_referred_to_by ?_position.
- ?_position a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300393201;
- rdfs:label "Professional position";
- crm:P190_has_symbolic_content ?position.
- ?_constituentID crm:P67i_is_referred_to_by ?_cultureGroup.
- ?_cultureGroup a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300387171;
- rdfs:label "Culture Group";
- crm:P190_has_symbolic_content ?cultureGroup.
-}
-where {
- graph {
- $this makerPerson:ConstituentID ?constituentID.
- filter(?constituentID != "NULL")
- bind(iri(concat(str(), str(?constituentID))) as ?_constituentID).
- $this makerPerson:DisplayName ?displayName.
- optional {
- $this makerPerson:AlphaSort ?alphaSort.
- }
- optional {
- $this makerPerson:FirstName ?firstName.
- bind(bnode() as ?_firstName).
- }
- optional {
- $this makerPerson:MiddleName ?middleName.
- bind(bnode() as ?_middleName).
- }
- optional {
- $this makerPerson:LastName ?lastName.
- bind(bnode() as ?_lastName).
- }
- optional {
- $this makerPerson:NameTitle ?nameTitle.
- bind(bnode() as ?_nameTitle).
- }
- optional {
- $this makerPerson:Suffix ?suffix.
- bind(bnode() as ?_suffix).
- }
- optional {
- $this makerPerson:salutation ?salutation.
- bind(bnode() as ?_salutation).
- }
- optional {
- $this makerPerson:Institution ?institution.
- bind(bnode() as ?_institution).
- }
- optional {
- $this makerPerson:Biography ?biography.
- bind(bnode() as ?_biography).
- }
- optional {
- $this makerPerson:Nationality ?nationality.
- bind(bnode() as ?_nationality).
- }
- optional {
- $this makerPerson:School ?school.
- bind(bnode() as ?_school).
- }
- optional {
- $this makerPerson:Remarks ?remarks.
- bind(bnode() as ?_remarks).
- }
- optional {
- $this makerPerson:Position ?position.
- bind(bnode() as ?_position).
- }
- optional {
- $this makerPerson:CultureGroup ?cultureGroup.
- bind(bnode() as ?_cultureGroup).
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/makers-iterator.rq b/static/ao/makers-iterator.rq
deleted file mode 100644
index f839220..0000000
--- a/static/ao/makers-iterator.rq
+++ /dev/null
@@ -1,5 +0,0 @@
-prefix makerPerson:
-SELECT * WHERE {
- $this makerPerson:ConstituentID ?ConstituentID.
- filter(?ConstituentID != "NULL")
-}
\ No newline at end of file
diff --git a/static/ao/objectDates-generator.rq b/static/ao/objectDates-generator.rq
deleted file mode 100644
index 33fd6d3..0000000
--- a/static/ao/objectDates-generator.rq
+++ /dev/null
@@ -1,93 +0,0 @@
-prefix aat:
-prefix archiveRelated:
-prefix dct:
-prefix crm:
-prefix rdfs:
-construct {
- #DateBegin && DateEnd - check when they are present |This needs to be done because of the way in which source data is being supplied.
- ?objects crm:P108i_was_produced_by ?production.
- ?production a crm:E12_Production;
- crm:P4_has_time-span ?dates;
- rdfs:label ?dated.
- ?dates a crm:E52_Time-Span.
- ?dates crm:P82a_begin_of_the_begin ?newBeginDate;
- crm:P82b_end_of_the_end ?newEndDate.
-}
-where {
- graph {
- ?subject archiveRelated:ObjectNumber ?objectNumber.
- # ?subject ?objectNumberPredicate ?objectNumber.
- # filter(replace(str(?objectNumberPredicate),".*[/]","") = "ObjectNumber")
- bind(iri(concat(str(), str(?objectNumber))) as ?objects).
- #DateBegin && DateEnd - check when they are present |This needs to be done because of the way in which source data is being supplied.
- # DateBegin && DateEnd are not 0
- optional {
- $this archiveRelated:DateBegin ?dateBegin.
- filter(?dateBegin != "0000-01-01")
- $this archiveRelated:DateEnd ?dateEnd.
- filter(?dateEnd != "0000-01-01")
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- optional {
- $this archiveRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this archiveRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- $this archiveRelated:DateBegin ?dateBegin.
- $this archiveRelated:DateEnd ?dateEnd.
- bind(if(strstarts(?dateBegin, "-"), concat("0",strafter(?dateBegin,"-")), ?dateBegin) as ?newBeginDate).
- # Due to differences in the original data, some date manipulations were implemented. The end format of each date should be as follows: “-XXXX-XXXX-XX”.
- # Some of the dates included a year that has 3 digits instead of 4, and/or were missing the dash in front.
- # With these string manipulations, we ensure that the end results have the same format.
- bind(if(strstarts(?dateEnd, "-"), concat("0",strafter(?dateEnd,"-")), ?dateEnd) as ?newEndDate).
- }
- # DateBegin is not 0 && DateEnd is 0
- optional {
- $this archiveRelated:DateBegin ?dateBegin.
- filter(?dateBegin != "0000-01-01")
- $this archiveRelated:DateEnd ?dateEnd.
- filter(?dateEnd = "0000-01-01")
-
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- #Check whether 'Dated' is empty or not
- optional {
- $this archiveRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this archiveRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- # DateBegin
- $this archiveRelated:DateBegin ?dateBegin.
- bind(if(strstarts(?dateBegin, "-"), concat("0",strafter(?dateBegin,"-")), ?dateBegin) as ?newBeginDate).
- }
- # DateBegin is 0 && DateEnd is not 0
- optional {
- $this archiveRelated:DateBegin ?dateBegin.
- filter(?dateBegin = "0000-01-01")
- $this archiveRelated:DateEnd ?dateEnd.
- filter(?dateEnd != "0000-01-01")
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- #Check whether 'Dated' is empty or not
- optional {
- $this archiveRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this archiveRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- $this archiveRelated:DateBegin ?dateEnd.
- bind(if(strstarts(?dateEnd, "-"), concat("0",strafter(?dateEnd,"-")), ?dateEnd) as ?newEndDate).
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/objectDates-iterator.rq b/static/ao/objectDates-iterator.rq
deleted file mode 100644
index 34647dc..0000000
--- a/static/ao/objectDates-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix archiveRelated:
-select * where {
- $this archiveRelated:ObjectNumber ?objectNumber.
-}
\ No newline at end of file
diff --git a/static/ao/objectImages-generator.rq b/static/ao/objectImages-generator.rq
deleted file mode 100644
index 4bd4be6..0000000
--- a/static/ao/objectImages-generator.rq
+++ /dev/null
@@ -1,61 +0,0 @@
-prefix aat:
-prefix crm:
-prefix crmdig:
-prefix la:
-prefix objectImageURLs:
-prefix rdfs:
-construct {
- ?objectNumber a crm:E22_Human-Made_Object.
- #objectImages
- ?_objectNumber crm:P65_shows_visual_item _:visvualItem.
- _:visvualItem a crm:E36_Visual_Item;
- la:digitally_shown_by _:digitalObject.
- _:digitalObject a crmdig:D1_Digital_Object;
- rdfs:label "Digitized Image of Painting";
- crm:P2_has_type aat:300215302;
- la:access_point ?uri.
- _:digitalObject crm:P104_is_subject_to ?_SAlicense.
- ?_SAlicense a crm:E30_Right;
- crm:P2_has_type .
- _:digitalObject crm:P67i_is_referred_to_by ?_DEEDlicenseLabel.
- ?_DEEDlicenseLabel a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300435434;
- rdfs:label ;
- crm:P190_has_symbolic_content ?authValue.
- _:digitalObject crm:P104_is_subject_to ?_NDlicense.
- ?_license a crm:E30_Right;
- crm:P2_has_type .
- _:digitalObject crm:P67i_is_referred_to_by ?_licenseLabel.
- ?_licenseLabel a crm:E33_E41_Linguistic_Appellation;
- crm:P2_has_type aat:300435434;
- rdfs:label ?authValue;
- crm:P190_has_symbolic_content ?authValue.
-}
-where {
- graph {
- $this objectImageURLs:ObjectNumber ?object.
- filter(regex(?object, "^[a-zA-Z]+-\\d+-\\d+$") || regex(?object, "^\\d+-\\d+[a-zA-Z]$") || regex(?object, "^\\d+-\\d+$"))
- # Originally, in the corresponding ETL, this iteration checks whether the created IRI is valid.
- # This action is not directly possible using SPARQL, hence a different approach was used to perform a similar action.
- # In this case, we check whether the value from the wanted key is in the desired format using regex.
- bind(iri(concat(str(), str(?object))) as ?objectNumber).
- optional {
- filter(objectImageURLs:AuthValue != "CC-BY-SA 4.0" || objectImageURLs:AuthValue != "CC-BY-SA 4.0 NMVW/WM")
- bind(bnode() as ?_SAlicense)
- }
- optional {
- filter(objectImageURLs:AuthValue != "Public domain" || objectImageURLs:AuthValue != "PD-anon-70-EU")
- $this objectImageURLs:AuthValue ?authValue.
- bind(bnode() as ?_DEEDlicenseLabel)
- }
- optional {
- filter(objectImageURLs:AuthValue != "CC-BY-NC-ND 4.0")
- bind(bnode() as ?_NDlicense)
- }
- optional {
- filter(objectImageURLs:AuthValue != "Copyrightstatus onbekend")
- $this objectImageURLs:AuthValue ?authValue.
- bind(bnode() as ?_licenseLabel)
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/objectImages-iterator.rq b/static/ao/objectImages-iterator.rq
deleted file mode 100644
index 0b09596..0000000
--- a/static/ao/objectImages-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix objectImageURLs:
-select * where {
- $this objectImageURLs:ObjectNumber ?object.
-}
\ No newline at end of file
diff --git a/static/ao/objectLocationDates-generator.rq b/static/ao/objectLocationDates-generator.rq
deleted file mode 100644
index cb08df7..0000000
--- a/static/ao/objectLocationDates-generator.rq
+++ /dev/null
@@ -1,103 +0,0 @@
-prefix aat:
-prefix locationRelated:
-prefix dct:
-prefix crm:
-prefix rdfs:
-construct {
- #DateBegin && DateEnd - check when they are present |This needs to be done because of the way in which source data is being supplied.
- ?objects crm:P108i_was_produced_by ?production.
- ?production a crm:E12_Production;
- crm:P4_has_time-span ?dates;
- rdfs:label ?dated.
- ?dates a crm:E52_Time-Span.
- ?dates crm:P82a_begin_of_the_begin ?newDateBeginCombined;
- crm:P82b_end_of_the_end ?newDateEndCombined.
-}
-where {
- graph {
- $this locationRelated:ObjectNumber ?objectNumber.
- bind(iri(concat(str(), str(?objectNumber))) as ?objects).
- #DateBegin && DateEnd - check when they are present |This needs to be done because of the way in which source data is being supplied.
- # DateBegin && DateEnd are not 0
- optional {
- $this locationRelated:DateBegin ?dateBegin.
- $this locationRelated:DateEnd ?dateEnd.
- filter(?dateBegin != "0" && ?dateEnd != "0")
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- optional {
- $this locationRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this locationRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- bind(if(strstarts(?dateBegin, "-"),concat("0", strafter(?dateBegin, "-")),?dateBegin) as ?newBeginDate)
- bind(if(strlen(?newBeginDate) = 10, concat("-", ?newBeginDate),
- if(strlen(?newBeginDate) = 3, concat("-0", ?newBeginDate, "-01-01"),
- if(strlen(?newBeginDate) = 4,concat("-", ?newBeginDate, "-01-01"),
- if(strlen(?newBeginDate) = 1, concat("-000", ?newBeginDate, "-01-01"), ?newBeginDate)
- )
- )
- ) as ?newDateBeginCombined)
- bind(if(strstarts(?dateEnd, "-"),concat("0", strafter(?dateEnd, "-")),?dateEnd) as ?newEndDate)
- bind(if(strlen(?newEndDate) = 10, concat("-", ?newEndDate),
- if(strlen(?newEndDate) = 3, concat("-0", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 4,concat("-", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 1, concat("-000", ?newEndDate, "-01-01"), ?newEndDate)
- )
- )
- ) as ?newDateEndCombined)
-
- # The data for this ETL is very inconsistent, this is used in order to normalize all dates so they have the same format "-XXXX-XX-XX"
- }
- # DateBegin is not 0 && DateEnd is 0
- optional {
- $this locationRelated:DateBegin ?dateBegin.
- $this locationRelated:DateEnd ?dateEnd.
- filter(?dateBegin = "0" && ?dateEnd != "0")
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- #Check whether 'Dated' is empty or not
- optional {
- $this locationRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this locationRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- bind(if(strstarts(?dateEnd, "-"),concat("0", strafter(?dateEnd, "-")),?dateEnd) as ?newEndDate)
- bind(if(strlen(?newEndDate) = 10, concat("-", ?newEndDate),
- if(strlen(?newEndDate) = 3, concat("-0", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 4,concat("-", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 1, concat("-000", ?newEndDate, "-01-01"), ?newEndDate)))) as ?newDateEndCombined)
- }
- # DateBegin is 0 && DateEnd is not0
- optional {
- $this locationRelated:DateBegin ?dateBegin.
- $this locationRelated:DateEnd ?dateEnd.
- filter(?dateBegin = "0" && ?dateEnd != "0")
- bind(bnode() as ?production).
- bind(bnode() as ?dates).
- #Check whether 'Dated' is empty or not
- optional {
- $this locationRelated:Dated ?dated.
- }
- optional {
- filter not exists{
- $this locationRelated:Dated ?dated.
- }
- bind("DateBegin and DateEnd" as ?dated)
- }
- bind(if(strstarts(?dateEnd, "-"),concat("0", strafter(?dateEnd, "-")),?dateEnd) as ?newEndDate)
- bind(if(strlen(?newEndDate) = 10, concat("-", ?newEndDate),
- if(strlen(?newEndDate) = 3, concat("-0", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 4,concat("-", ?newEndDate, "-01-01"),
- if(strlen(?newEndDate) = 1, concat("-000", ?newEndDate, "-01-01"), ?newEndDate)))) as ?newDateEndCombined)
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/objectLocationDates-iterator.rq b/static/ao/objectLocationDates-iterator.rq
deleted file mode 100644
index 8b1eb62..0000000
--- a/static/ao/objectLocationDates-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix locationRelated:
-select * where {
- $this locationRelated:ObjectNumber ?objectNumber.
-}
\ No newline at end of file
diff --git a/static/ao/objectLocations-generator.rq b/static/ao/objectLocations-generator.rq
deleted file mode 100644
index b55e7bc..0000000
--- a/static/ao/objectLocations-generator.rq
+++ /dev/null
@@ -1,198 +0,0 @@
-prefix aat:
-prefix dct:
-prefix crm:
-prefix rdfs:
-prefix objectLocations:
-prefix skos:
-construct {
- ?_objectNumber a crm:E22_Human-Made_Object.
- #ObjectNumber
- ?_objectNumber crm:P1_is_identified_by ?_number.
- ?_number a crm:E42_Identifier;
- crm:P2_has_type aat:300404626;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?objectNumber.
- #ObjectID
- ?_objectNumber crm:P1_is_identified_by _:objectID.
- _:objectID a crm:E42_Identifier;
- crm:P2_has_type aat:300445023;
- crm:P2_has_type aat:300404664;
- rdfs:label "Alias of the identification number";
- crm:P190_has_symbolic_content ?objectID.
- # #ObjectName
- ?_objectNumber crm:P1_is_identified_by _:objectName.
- _:objectName a crm:E55_Type;
- rdfs:label "Intended use";
- crm:P190_has_symbolic_content ?objectID.
- #Title - check if it is present
- ?objects dct:title ?title.
- #Medium - check if it is present
- ?objects crm:P45_consists_of ?skolemMeduim.
- ?skolemMeduim a crm:E57_Material;
- rdfs:label "Material";
- crm:P190_has_symbolic_content ?medium.
- # Remarks (should only be created when Remarks is not empty)
- ?objects crm:P67i_is_referred_to_by ?skolemNodeRemarks.
- ?skolemNodeRemarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Remarks" ;
- crm:P190_has_symbolic_content ?remarks.
- #Description - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemDescription.
- ?skolemDescription a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435416;
- rdfs:label "Description";
- crm:P190_has_symbolic_content ?description.
- #Provenance - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemProvenance.
- ?skolemProvenance a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300444173;
- rdfs:label "Provenance";
- crm:P190_has_symbolic_content ?provenance.
- #Notes - check if it is empty
- ?objects crm:P3_has_note ?notes.
- #RelatedWorks - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemRelatedWorks.
- ?skolemRelatedWorks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300444120;
- rdfs:label "Related works";
- crm:P190_has_symbolic_content ?relatedWorks.
- # HistAttributions - check if it is empty
- ?objects skos:historyNote ?histAttributions.
- #CuratorialRemarks - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemCuratorialRemarks.
- ?skolemCuratorialRemarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Curatorial remarks";
- crm:P190_has_symbolic_content ?curatorialRemarks.
- #Dimensions & DimensionRemarks
- #Dimensions and Dimesions remarks not empty
- ?objects crm:P43_has_dimension ?dimensionsAndRemarks.
- ?dimensionsAndRemarks a crm:E54_Dimension;
- rdfs:label "Dimesions";
- crm:P3_has_note ?dimesionsRemarks.
- #DimensionRemarks is not empty
- ?object crm:P43_has_dimension ?onlyDimesionsRemarks.
- ?onlyDimesionsRemarks a crm:E54_Dimension;
- rdfs:label "DimensionRemarks";
- crm:P3_has_note ?dimesionsRemarks.
- #Dimension is not empty
- ?object crm:P43_has_dimension ?onlyDimesions.
- ?onlyDimesions a crm:E54_Dimension;
- rdfs:label "Dimensions";
- crm:P3_has_note ?dimensions.
- #Signed
- ?objects crm:P128_carries ?hashedSigned.
- ?hashedSigned a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300189326;
- rdfs:label "Signed";
- crm:P190_has_symbolic_content ?signed.
- #Inscribed
- ?objects crm:P128_carries ?hashedInscribed.
- ?hashedInscribed a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300028702;
- rdfs:label "Inscribed";
- crm:P190_has_symbolic_content ?inscribed.
- #Markings
- ?objects crm:P128_carries ?hashedMarkings.
- ?hashedMarkings a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300028744;
- rdfs:label "Markings";
- crm:P190_has_symbolic_content ?markings.
-}
-where {
- graph {
- #objectNumber
- $this objectLocations:ObjectNumber ?objectNumber.
- bind(iri(concat(str(), str(?objectNumber))) as ?_objectNumber).
- bind(iri(concat(str(), str(?objectNumber))) as ?_number).
- optional {
- $this objectLocations:ObjectID ?objectID.
- }
- #Title
- optional {
- $this objectLocations:Title ?title.
- }
- # Medium - check if medium is empty or not
- optional {
- $this objectLocations:Medium ?medium.
- bind(bnode() as ?skolemMeduim).
- }
- # Remarks (should only be created when Remarks is not empty)
- optional {
- $this objectLocations:Remarks ?remarks.
- filter(?remarks != "\r\n")
- bind(bnode() as ?skolemNodeRemarks).
- }
- # Description - check if description is empty or not
- optional {
- $this objectLocations:Description ?description.
- bind(bnode() as ?skolemDescription).
- }
- #Provenance
- optional {
- $this objectLocations:Provenance ?provenance.
- bind(bnode() as ?skolemProvenance).
- }
- #Notes
- optional {
- $this objectLocations:Notes ?notes.
- }
- #RelatedWorks
- optional {
- $this objectLocations:RelatedWorks ?relatedWorks.
- bind(bnode() as ?skolemRelatedWorks).
- }
- #HistAttributions
- optional {
- $this objectLocations:HistAttributions ?histAttributions.
- }
- #CuratorialRemarks
- optional {
- $this objectLocations:CuratorialRemarks ?curatorialRemarks.
- bind(bnode() as ?skolemCuratorialRemarks).
- }
- #Dimensions and DimensionRemarks are not empty
- optional {
- $this objectLocations:Dimensions ?dimesions.
- filter(?dimesions != "[N.B.]" && ?dimesions != "[N.I.]")
- $this objectLocations:DimensionRemarks ?dimesionsRemarks.
- # specifically used hashedIri in ETL instead of skolemIri
- bind(iri(concat(str(), md5(str(?dimesions)), md5(str(?dimesionsRemarks)), md5(str(?objectNumber)))) as ?dimensionsAndRemarks).
- }
- #DimensionRemarks is not empty
- optional {
- $this objectLocations:DimensionRemarks ?dimesionsRemarks.
- filter not exists {
- $this objectLocations:Dimensions ?dimesions.
- }
- # specifically used hashedIri in ETL instead of skolemIri
- bind(iri(concat(str(), md5(str(?dimesionsRemarks)), md5(str(?objectNumber)))) as ?onlyDimesionsRemarks).
- }
- #Dimension is not empty
- optional {
- $this objectLocations:Dimensions ?dimesions.
- filter(?dimesions != "[N.B.]" && ?dimesions != "[N.I.]")
- filter not exists {
- $this objectLocations:DimensionRemarks ?dimesionsRemarks.
- }
- # specifically used hashedIri in ETL instead of skolemIri
- bind(bnode() as ?onlyDimesions).
- }
- #Signed
- optional {
- $this objectLocations:Signed ?signed.
- bind(bnode() as ?hashedSigned).
- }
- #Inscribed
- optional {
- $this objectLocations:Inscribed ?inscribed.
- bind(bnode() as ?hashedInscribed).
- }
- #Markings
- optional {
- $this objectLocations:Markings ?markings.
- bind(bnode() as ?hashedMarkings).
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/objectLocations-iterator.rq b/static/ao/objectLocations-iterator.rq
deleted file mode 100644
index bb37814..0000000
--- a/static/ao/objectLocations-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix objectLocations:
-select * where {
- $this objectLocations:ObjectNumber ?objectNumber.
-}
\ No newline at end of file
diff --git a/static/ao/objects-generator.rq b/static/ao/objects-generator.rq
deleted file mode 100644
index c4a1aeb..0000000
--- a/static/ao/objects-generator.rq
+++ /dev/null
@@ -1,158 +0,0 @@
-prefix skos:
-prefix aat:
-prefix dct:
-prefix crm:
-prefix rdfs:
-prefix archiveRelated:
-prefix la:
-construct {
- ?objects a crm:E22_Human-Made_Object.
- #ObjectNumber
- ?objects crm:P1_is_identified_by _:objectNumber.
- _:objectNumber a crm:E42_Identifier;
- crm:P2_has_type aat:300404626;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?objectNumber.
- #ObjectID
- #Title - check if it is present
- ?objects dct:title ?title.
- #Medium - check if it is present
- ?objects crm:P45_consists_of ?skolemMeduim.
- ?skolemMeduim a crm:E57_Material;
- rdfs:label "Material";
- crm:P190_has_symbolic_content ?medium.
- # Remarks (should only be created when Remarks is not empty)
- ?objects crm:P67i_is_referred_to_by ?skolemNodeRemarks.
- ?skolemNodeRemarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Remarks" ;
- crm:P190_has_symbolic_content ?remarks.
- #Description - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemDescription.
- ?skolemDescription a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435416;
- rdfs:label "Description";
- crm:P190_has_symbolic_content ?description.
- #Provenance - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemProvenance.
- ?skolemProvenance a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300444173;
- rdfs:label "Provenance";
- crm:P190_has_symbolic_content ?provenance.
- #Notes - check if it is empty
- ?objects crm:P3_has_note ?notes.
- #RelatedWorks - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemRelatedWorks.
- ?skolemRelatedWorks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300444120;
- rdfs:label "Related works";
- crm:P190_has_symbolic_content ?relatedWorks.
- # HistAttributions - check if it is empty
- ?objects skos:historyNote ?histAttributions.
- #CuratorialRemarks - check if it is empty
- ?objects crm:P67i_is_referred_to_by ?skolemCuratorialRemarks.
- ?skolemCuratorialRemarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Curatorial remarks";
- crm:P190_has_symbolic_content ?curatorialRemarks.
- #Dimensions & DimensionRemarks
- #Signed
- ?objects crm:P128_carries ?hashedSigned.
- ?hashedSigned a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300189326;
- rdfs:label "Signed";
- crm:P190_has_symbolic_content ?signed.
- #Inscribed
- ?objects crm:P128_carries ?hashedInscribed.
- ?hashedInscribed a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300028702;
- rdfs:label "Inscribed";
- crm:P190_has_symbolic_content ?inscribed.
- #Markings
- ?objects crm:P128_carries ?hashedMarkings.
- ?hashedMarkings a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300028744;
- rdfs:label "Markings";
- crm:P190_has_symbolic_content ?markings.
- #If the object is a member of a Site set ---> this key is not part of Archive-related csv
- ?objects la:member_of ?siteID.
- #HistEventID & Subevent1 ---> not part of archives, part of Event-related_Objects.csv
- ?objects crm:P141i_was_assigned_by ?histEvents.
- ?histEvents a crm:E13_Attribute_Assignment;
- crm:P177_assigned_property_of_type crm:P12i_was_present_at;
- rdfs:label "Relation with the event";
- crm:P141_assigned ?histEventsNode.
- ?histEvents crm:P67i_is_referred_to_by ?subEvents.
- ?subEvents a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- crm:P190_has_symbolic_content ?Subevent1.
-}
-where {
- graph {
- #objectNumber
- $this archiveRelated:ObjectNumber ?objectNumber.
- bind(iri(concat(str(), str(?objectNumber))) as ?objects).
- #title
- optional {
- $this ?titlePredicate ?title.
- filter(replace(str(?titlePredicate),".*[/]","") = "Title")
- }
- # Remarks (should only be created when Remarks is not empty)
- optional {
- filter(?remarks != "\r\n")
- bind(bnode() as ?skolemNodeRemarks).
- $this archiveRelated:Remarks ?remarks.
- }
- # Description - check if description is empty or not
- optional {
- $this archiveRelated:Description ?description.
- bind(bnode() as ?skolemDescription).
- }
- # Medium - check if medium is empty or not
- optional {
- $this archiveRelated:Medium ?medium.
- bind(bnode() as ?skolemMeduim).
- }
- #Provenance
- optional {
- $this archiveRelated:Provenance ?provenance.
- bind(bnode() as ?skolemProvenance).
- }
- #Notes
- optional {
- $this archiveRelated:Notes ?notes.
- }
- #RelatedWorks
- optional {
- $this archiveRelated:RelatedWorks ?relatedWorks.
- bind(bnode() as ?skolemRelatedWorks).
- }
- #HistAttributions
- optional {
- $this archiveRelated:HistAttributions ?histAttributions.
- }
- #CuratorialRemarks
- optional {
- $this archiveRelated:CuratorialRemarks ?curatorialRemarks.
- bind(bnode() as ?skolemCuratorialRemarks).
- }
- #Signed
- optional {
- $this archiveRelated:Signed ?signed.
- # specifically used hashedIri in ETL instead of skolemIri
- bind(bnode() as ?_hashedSigned).
- }
- #Inscribed
- optional {
- $this archiveRelated:Inscribed ?inscribed.
- # specifically used hashedIri in ETL instead of skolemIri
- bind(bnode() as ?_hashedInscribed).
- }
- #Markings
- optional {
- $this archiveRelated:Markings ?markings.
- # specifically used hashedIri in ETL instead of skolemIri
- bind(bnode() as ?_hashedMarkings).
- }
- }
-}
\ No newline at end of file
diff --git a/static/ao/objects-iterator.rq b/static/ao/objects-iterator.rq
deleted file mode 100644
index 34647dc..0000000
--- a/static/ao/objects-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix archiveRelated:
-select * where {
- $this archiveRelated:ObjectNumber ?objectNumber.
-}
\ No newline at end of file
diff --git a/static/ao/sites-generator.rq b/static/ao/sites-generator.rq
deleted file mode 100644
index 1783d47..0000000
--- a/static/ao/sites-generator.rq
+++ /dev/null
@@ -1,93 +0,0 @@
-prefix aat:
-prefix colonialHeritage:
-prefix crm:
-prefix dct:
-prefix la:
-prefix rdfs:
-construct {
- ?siteID a la:Set;
- crm:P2_has_type aat:300378926;
- rdfs:label ?siteName.
- #siteID
- ?siteID crm:P1_is_identified_by _:skolemNodeSiteID.
- _:skolemNodeSiteID a crm:E42_Identifier ;
- crm:P2_has_type aat:300404626 ;
- rdfs:label "Identification number";
- crm:P190_has_symbolic_content ?siteID.
- # "LocationNote"=EN
- ?siteID crm:P67i_is_referred_to_by _:skolemNodeLocationNodeEn.
- _:skolemNodeLocationNodeEn a crm:E33_Linguistic_Object ;
- crm:P2_has_type aat:300435416 ;
- rdfs:label "Description in English";
- # locationNotes could be HTML or string literal
- crm:P190_has_symbolic_content ?locationNotes;
- crm:P72_has_language aat:300388277.
- # "Environment"=NL
- ?siteID crm:P67i_is_referred_to_by _:skolemNodeEnvironment.
- _:skolemNodeEnvironment a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435416;
- rdfs:label "Description in Dutch" ;
- crm:P190_has_symbolic_content ?environment;
- crm:P72_has_language aat:300411849.
- # # "Description"=ID
- ?siteID crm:P67i_is_referred_to_by _:skolemNodeDesc.
- _:skolemNodeDesc a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435416;
- rdfs:label "Description in Indonesian" ;
- crm:P190_has_symbolic_content ?description;
- crm:P72_has_language aat:300388460.
- # Remarks (should only be created when Remarks is not empty)
- ?siteID crm:P67i_is_referred_to_by ?skolemNodeRemarks.
- ?skolemNodeRemarks a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Remarks" ;
- crm:P190_has_symbolic_content ?remarks.
- # Dimensions (should only be created when Dimensions is not empty)
- ?siteID crm:P67i_is_referred_to_by ?skolemNodeDimensions.
- ?skolemNodeDimensions a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300418049;
- rdfs:label "Temporal or spatial coverage" ;
- crm:P190_has_symbolic_content ?dimensions.
- # ResearcherComments
- ?siteID crm:P67i_is_referred_to_by _:skolemNodeResearcherComments.
- _:skolemNodeResearcherComments a crm:E33_Linguistic_Object;
- crm:P2_has_type aat:300435415;
- rdfs:label "Researcher comment" ;
- crm:P190_has_symbolic_content ?researcherComment.
- # IsPublic (should only be created when IsPublic is equal to "1")
- ?siteID dct:accessRights ?skolemNodeIsTrue.
- ?skolemNodeIsTrue a dct:RightsStatement;
- rdfs:label "Yes, for public use".
-}
-where {
- $this colonialHeritage:siteID ?siteID0.
- bind(iri(concat(str(), ?siteID0)) as ?siteID).
- #siteName
- $this colonialHeritage:siteName ?siteName.
- # "LocationNote"=EN
- $this colonialHeritage:LocationNotes ?locationNotes.
- # "Environment"=NL
- $this colonialHeritage:Environment ?environment.
- # "Description"=ID
- $this colonialHeritage:Description ?description.
- # Dimensions (should only be created when Dimensions is not empty)
- $this colonialHeritage:Dimensions ?dimensions.
- optional {
- filter(?dimensions != "\r\n")
- bind(bnode() as ?skolemNodeDimensions).
- }
- # Remarks (should only be created when Remarks is not empty)
- $this colonialHeritage:Remarks ?remarks.
- optional {
- filter(?remarks != "\r\n")
- bind(bnode() as ?skolemNodeRemarks).
- }
- # ResearcherComments
- $this colonialHeritage:ResearcherComments ?researcherComment.
- # IsPublic (should only be created when IsPublic is equal to "1")
- $this colonialHeritage:IsPublic ?isPublic.
- optional {
- filter(?isPublic = "1")
- bind(bnode() as ?skolemNodeIsTrue).
- }
-}
\ No newline at end of file
diff --git a/static/ao/sites-iterator.rq b/static/ao/sites-iterator.rq
deleted file mode 100644
index dca9f31..0000000
--- a/static/ao/sites-iterator.rq
+++ /dev/null
@@ -1,4 +0,0 @@
-prefix colonialHeritage:
-select * where {
- $this colonialHeritage:SiteID ?oldobject.
-}
\ No newline at end of file