Skip to content

Instantly share code, notes, and snippets.

Avatar

Pascal Christoph dr0i

View GitHub Profile
View gist:e34ef5bf10326488ef65de350ae9a780
Das folgende Script:
curl -XGET 'http://weywot3.hbz-nrw.de:9200/almaresources/_search?q=natureOfContent.id:*&pretty=true' -d '
{
"aggs": {
"aggs1": {
"terms": {
"field": "natureOfContent.id",
"size": 150
}
}
View rpg
https://gadel.org/story/kalender-02-12-2011.html:
eine recht gutes Blaustahl Kurzschwert, letztes erhält Altamir,
View gist:c649f05af0cc32aa5baec4b3c04871d2
"spatial" : [ {
"id" : "https://nwbib.de/spatial#N05",
"type" : [ "Concept" ],
"source" : {
"id" : "https://nwbib.de/spatial",
"label" : "Raumsystematik der Nordrhein-Westfälischen Bibliographie"
},
"label" : "Westfalen",
"notation" : "05",
"focus" : {
View sendGndIdsOfLobidResourcesAsLDN.sh
# Simulates the load created by multiple senders to an LDN Inbox
# by getting all yesterdays updates of lobid-resources and their use of gnd ids,
# POSTing in a time frame of roughly 10h by exploitmng an AI to computate delays.
#
# Optional first parameter: a date following the pattern YYYYMMDD (like in 19701010)
#
# created: 20190412
# author: dr0i
DATE=$1
View RecursionStream.java
public class RecursionStream {
public static void main(String... args) {
getAllJsonNodes(node)//
.peek(p -> System.out.println("endpeek" + p))
.forEach(p -> System.out.println("end" + cnt + ":" + p.toString()));
}
private Stream<JsonNode> getAllJsonNodes(JsonNode node) {
cnt++;
Iterable<Entry<String, JsonNode>> iterable = () -> node.fields();
return StreamSupport.stream(iterable.spliterator(), false)
@dr0i
dr0i / loc-bibframe-works-example.jsonld
Created Jul 10, 2018
loc-bibframe-works-example.jsonld
View loc-bibframe-works-example.jsonld
{
"@context" : "http://lobid.org/resources/context.jsonld",
"Admin Metadata" : {
"creationDate" : "1994-02-10",
"descriptionConventions" : {
"code" : "aacr",
"type" : [ "DescriptionConventions" ]
},
"encodingLevel" : {
"code" : "5",
View loc-bibframe-jsonld
{
"@context" : "http://lobid.org/resources/context.jsonld",
"Admin Metadata" : {
"changeDate" : "2006-06-29T07:37:26",
"creationDate" : "1999-06-29",
"descriptionConventions" : {
"code" : "aacr",
"type" : [ "DescriptionConventions" ]
},
"descriptionModifier" : {
View gist:cb45731d0f95e7b2f21c1d215f2753e0
000046099|HT000052997
000396821|HT000452509
001285193|HT003427665
005287461|HT001321732
006447401|HT004107465
010939223|HT012787448
011237068|HT012909323
011475588|HT013149479
013240130|HT014108663
016523140|HT015478944
View geoMappingScoreLesser4.csv
Occurence Label Score Wikidata-ID
4 Aachen Bildchen 1.7919801 Q1017
1 Aachen Deltourserb 1.7919801 Q1017
6 Aachen Eilendorf 1.7919801 Q1017
3 Aachen Frankenberg 3.2082725 Q1390913
24 Aachen Haaren 3.0760581 Q1120297
2 Aachen Krummerück 1.7919801 Q1017
4 Aachen Laurensberg 1.7919801 Q1017
2 Aachen Melaten 1.7919801 Q1017
1 Aachen Mitte 2.4189296 Q1020752
View missingGeocoordsWikidata
Adamsfeld: Q28531092
Altenufer: Q28845194
Bandesmühle: Q24928613
Bathey: Q5994963
Bavert: Q28528026
Bergerbrühl: Q24175856
Bergerfurth: Q26208579
Blumental: Q26271448
Bochum-Süd: Q3641512
Borkenwirthe: Q23854151