Skip to content

Commit

Permalink
Adjust transformation of placeOfActivity (RPB-102)
Browse files Browse the repository at this point in the history
  • Loading branch information
maipet committed Nov 2, 2023
1 parent e8f8071 commit de896ef
Show file tree
Hide file tree
Showing 14 changed files with 55 additions and 32 deletions.
20 changes: 13 additions & 7 deletions conf/output/test-output-rppd-lobid-0.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,26 @@
"id" : "https://d-nb.info/gnd/4032009-1"
} ],
"placeOfActivity" : [ {
"label" : "Köln"
"label" : "Köln",
"id" : "https://rpb.lobid.org/dummi/Köln"
}, {
"label" : "München"
"label" : "München",
"id" : "https://rpb.lobid.org/dummi/München"
}, {
"label" : "Xanten"
"label" : "Xanten",
"id" : "https://rpb.lobid.org/dummi/Xanten"
}, {
"label" : "Bayreuth"
"label" : "Bayreuth",
"id" : "https://rpb.lobid.org/dummi/Bayreuth"
}, {
"label" : "https://rpb.lobid.org/spatial#n14000501",
"label" : "Boppard, Stadt",
"id" : "https://rpb.lobid.org/spatial#n14000501"
}, {
"label" : "Barcelona"
"label" : "Barcelona",
"id" : "https://rpb.lobid.org/dummi/Barcelona"
}, {
"label" : "Frankfurt am Main"
"label" : "Frankfurt am Main",
"id" : "https://rpb.lobid.org/dummi/Frankfurt am Main"
}, {
"label" : "Mainz, Kreisfreie Stadt",
"id" : "https://rpb.lobid.org/spatial#n31500000"
Expand Down
6 changes: 4 additions & 2 deletions conf/output/test-output-rppd-lobid-10.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,11 @@
"label" : "Diez,Stadt",
"id" : "https://rpb.lobid.org/spatial#n14103029"
}, {
"label" : "Wiesbaden"
"label" : "Wiesbaden",
"id" : "https://rpb.lobid.org/dummi/Wiesbaden"
}, {
"label" : "Berlin"
"label" : "Berlin",
"id" : "https://rpb.lobid.org/dummi/Berlin"
} ],
"dateOfBirth" : [ "1825-06-09" ],
"dateOfDeath" : [ "1880-01-01" ],
Expand Down
6 changes: 4 additions & 2 deletions conf/output/test-output-rppd-lobid-11.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@
"id" : "https://rpb.lobid.org/sw/00Sn02x0286a"
} ],
"placeOfActivity" : [ {
"label" : "Schweden"
"label" : "Schweden",
"id" : "https://rpb.lobid.org/dummi/Schweden"
}, {
"label" : "Berlin"
"label" : "Berlin",
"id" : "https://rpb.lobid.org/dummi/Berlin"
} ],
"dateOfBirth" : [ "1895-02-11" ],
"dateOfDeath" : [ "1976-03-03" ],
Expand Down
6 changes: 4 additions & 2 deletions conf/output/test-output-rppd-lobid-12.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@
"label" : "Koblenz, Kreisfreie Stadt",
"id" : "https://rpb.lobid.org/spatial#n11100000"
}, {
"label" : "London"
"label" : "London",
"id" : "https://rpb.lobid.org/dummi/London"
}, {
"label" : "New York, NY"
"label" : "New York, NY",
"id" : "https://rpb.lobid.org/dummi/New York, NY"
} ],
"dateOfBirth" : [ "1818-01-10" ],
"dateOfDeath" : [ "1870-12-30" ],
Expand Down
3 changes: 2 additions & 1 deletion conf/output/test-output-rppd-lobid-14.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
"id" : "https://d-nb.info/gnd/4032009-1"
} ],
"placeOfActivity" : [ {
"label" : "Brühl <Rhein-Erft-Kreis>"
"label" : "Brühl <Rhein-Erft-Kreis>",
"id" : "https://rpb.lobid.org/dummi/Brühl <Rhein-Erft-Kreis>"
} ],
"gender" : [ {
"id" : "https://d-nb.info/standards/vocab/gnd/gender#male",
Expand Down
3 changes: 2 additions & 1 deletion conf/output/test-output-rppd-lobid-16.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"label" : "Koblenz, Kreisfreie Stadt",
"id" : "https://rpb.lobid.org/spatial#n11100000"
}, {
"label" : "Köln"
"label" : "Köln",
"id" : "https://rpb.lobid.org/dummi/Köln"
} ],
"dateOfBirth" : [ "1796-12-20" ],
"dateOfDeath" : [ "1844-02-29" ],
Expand Down
6 changes: 4 additions & 2 deletions conf/output/test-output-rppd-lobid-17.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,11 @@
"id" : "https://d-nb.info/gnd/4158589-6"
} ],
"placeOfActivity" : [ {
"label" : "Remscheid"
"label" : "Remscheid",
"id" : "https://rpb.lobid.org/dummi/Remscheid"
}, {
"label" : "Bünde"
"label" : "Bünde",
"id" : "https://rpb.lobid.org/dummi/Bünde"
}, {
"label" : "Oberlahnstein",
"id" : "https://rpb.lobid.org/spatial#n141000750200"
Expand Down
4 changes: 2 additions & 2 deletions conf/output/test-output-rppd-lobid-18.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@
"id" : "https://d-nb.info/gnd/4035088-5"
} ],
"placeOfActivity" : [ {
"label" : "https://rpb.lobid.org/spatial#n14302229",
"label" : "Hachenburg, Stadt",
"id" : "https://rpb.lobid.org/spatial#n14302229"
}, {
"label" : "Bendorf, Stadt",
"id" : "https://rpb.lobid.org/spatial#n13700203"
}, {
"label" : "https://rpb.lobid.org/spatial#n14302287",
"label" : "Roßbach",
"id" : "https://rpb.lobid.org/spatial#n14302287"
}, {
"label" : "Altenkirchen (Westerwald), Stadt",
Expand Down
5 changes: 3 additions & 2 deletions conf/output/test-output-rppd-lobid-25.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@
"id" : "https://d-nb.info/gnd/4398834-9"
} ],
"placeOfActivity" : [ {
"label" : "Würzburg"
"label" : "Würzburg",
"id" : "https://rpb.lobid.org/dummi/Würzburg"
}, {
"label" : "https://rpb.lobid.org/spatial#n21100000",
"label" : "Trier, Kreisfreie Stadt",
"id" : "https://rpb.lobid.org/spatial#n21100000"
}, {
"label" : "Bernkastel",
Expand Down
2 changes: 1 addition & 1 deletion conf/output/test-output-rppd-lobid-26.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"id" : "https://d-nb.info/gnd/4441540-0"
} ],
"placeOfActivity" : [ {
"label" : "https://rpb.lobid.org/spatial#n23206296",
"label" : "Prüm, Stadt",
"id" : "https://rpb.lobid.org/spatial#n23206296"
}, {
"label" : "Wassenach",
Expand Down
5 changes: 3 additions & 2 deletions conf/output/test-output-rppd-lobid-36.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,14 @@
"id" : "https://d-nb.info/gnd/4013673-5"
} ],
"placeOfActivity" : [ {
"label" : "https://rpb.lobid.org/spatial#n14304048",
"label" : "Montabaur, Stadt",
"id" : "https://rpb.lobid.org/spatial#n14304048"
}, {
"label" : "Mainz, Kreisfreie Stadt",
"id" : "https://rpb.lobid.org/spatial#n31500000"
}, {
"label" : "Düsseldorf"
"label" : "Düsseldorf",
"id" : "https://rpb.lobid.org/dummi/Düsseldorf"
} ],
"dateOfBirth" : [ "1936-11-28" ],
"dateOfDeath" : [ "2023-05-30" ],
Expand Down
9 changes: 6 additions & 3 deletions conf/output/test-output-rppd-lobid-37.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,14 @@
"id" : "https://d-nb.info/gnd/4466532-5"
} ],
"placeOfActivity" : [ {
"label" : "Limburg, Lahn"
"label" : "Limburg, Lahn",
"id" : "https://rpb.lobid.org/dummi/Limburg, Lahn"
}, {
"label" : "Neesbach"
"label" : "Neesbach",
"id" : "https://rpb.lobid.org/dummi/Neesbach"
}, {
"label" : "Hünfelden"
"label" : "Hünfelden",
"id" : "https://rpb.lobid.org/dummi/Hünfelden"
} ],
"dateOfBirth" : [ "1935-05-25" ],
"dateOfDeath" : [ "2023-04-14" ],
Expand Down
6 changes: 4 additions & 2 deletions conf/output/test-output-rppd-lobid-38.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,11 @@
"id" : "https://d-nb.info/gnd/7607862-0"
} ],
"placeOfActivity" : [ {
"label" : "Jena"
"label" : "Jena",
"id" : "https://rpb.lobid.org/dummi/Jena"
}, {
"label" : "Köln"
"label" : "Köln",
"id" : "https://rpb.lobid.org/dummi/Köln"
} ],
"dateOfBirth" : [ "1823-05-24" ],
"dateOfDeath" : [ "1892-03-11" ],
Expand Down
6 changes: 3 additions & 3 deletions conf/rppd-to-lobid.fix
Original file line number Diff line number Diff line change
Expand Up @@ -118,11 +118,11 @@ do list(path:"f1no[]", "var": "$i")
prepend("$i.f1no", "https://rpb.lobid.org/spatial#n")
copy_field("$i.f1no", "placeOfActivity[].$append.label")
copy_field("$i.f1no", "placeOfActivity[].$last.id")
do list(path:"placeOfActivity[]", "var": "$i")
lookup("$i.label", "spatial_map")
end
lookup("placeOfActivity[].$last.label", "spatial_map")
else
copy_field("$i.f1no", "placeOfActivity[].$append.label")
prepend("$i.f1no", "https://rpb.lobid.org/dummi/")
copy_field("$i.f1no", "placeOfActivity[].$last.id")
end
end

Expand Down

0 comments on commit de896ef

Please sign in to comment.