goe-wikidata / doathon-20180214

About the event
Other
3 stars 1 forks source link

WD2GB (Wikidata to Geo-Browser) #2

Open FriedrichMueller opened 6 years ago

FriedrichMueller commented 6 years ago

WD2GB (Wikidata to Geo-Browser)

Related topics:

Results of the doathon: https://github.com/FriedrichMueller/WD2GB

Demo: https://mueller273.pages.gwdg.de/WD2GB/

Idea:

There are already different applications available that allow to visualize spatio-temporal data from Wikidata e.g. ViziData (https://github.com/arsylum/ViziData),

https://tools.wmflabs.org/wikishootme/#lat=51.539937099999996&lng=9.936693199999999&zoom=15,

https://tools.wmflabs.org/wikidata-todo/tempo_spatial_display.html,

https://tools.wmflabs.org/wikidata-todo/missing_images.html

The SUB has with the DARIAH-DE Geo-Browser (https://geobrowser.de.dariah.eu/, https://github.com/DARIAH-DE/PLATIN) an explorative tool for spatio-temporal data. The Idea is to make spatio-temporal data from Wikidata available with the Geo-Browser. This means creating a tool that allows to predefine Wikidata queries and that converts the result sets into Geo-Browser specific data format (https://www.dropbox.com/s/httk62myn2tsi4p/M3.3.2_eConnect_KML_Specification_v1.0_UGOE.pdf) and visualize them afterwards.

One option is to start with an application that offers a graphical query-builder. The Wikidata-SDK (https://github.com/maxlath/wikidata-sdk) could be reused to generate the result sets. A conversion functionality has to be created to bring the query results into a Geo-Browser conform data format. The final data can be visualized with the Geo-Browser.

Further possibilities:

Adding a “Add Wikidata identifier”-Button to the Datasheet Editor (https://geobrowser.de.dariah.eu/edit/index.html) Could be realized as a mapping between Geonames and Wikidata (see https://opendata.stackexchange.com/questions/3728/mapping-between-wikidata-and-geonames/3731)

nichtich commented 6 years ago

We came up with a sample query:

SELECT DISTINCT ?Name ?Address ?Description ?Longitude ?Latitude (year(?inception) as ?TimeStamp) 
WHERE {
  SERVICE wikibase:label { 
    bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". 
    ?band rdfs:label ?Name .
    ?band schema:description ?Description .
    ?place rdfs:label ?Address.
  }

  ?band wdt:P136 wd:Q3071.
  ?band wdt:P31 wd:Q215380.
  ?band wdt:P740 ?place.

  ?place p:P625 ?coordinate.
  ?coordinate psv:P625 ?coordinate_node.
  ?coordinate_node wikibase:geoLatitude ?Latitude.
  ?coordinate_node wikibase:geoLongitude ?Longitude.
  ?band wdt:P571 ?inception.
}

download as CSV and upload to Geobrowser is possible.