Closed philboeselager closed 8 years ago
Deployed to gaia, see: http://gaia.hbz-nrw.de:7400/geodata?q=K%C3%B6ln
We also need the wikidata ID (Q365
in this case) or entity URI (http://www.wikidata.org/entity/Q365
) for the spatial
field, see https://github.com/hbz/nwbib/issues/83#issuecomment-155806824.
Also, the response doesn't look correct for the entries we need an imporvement for: part sof a town like "Köln-Ehrenfeld". Köln (wikidata entity), Köln-Ehrenfeld (wikidata entity), and Köln-Mülheim (wikidata entity) all deliver the same geo coordinates though they have different ones in wikidata.
Is the query template I provided in https://github.com/hbz/nwbib/issues/83#issuecomment-65620502 actually used here: https://www.wikidata.org/w/api.php?action=query&list=search&format=json&srsearch=$place_name
?
We also need the wikidata ID (Q365 in this case) or entity URI (http://www.wikidata.org/entity/Q365) for the spatial field, see hbz/nwbib#83 (comment).
So how do you want the result to look like then?
Also, the response doesn't look correct for the entries we need an imporvement for: part sof a town like "Köln-Ehrenfeld". Köln (wikidata entity), Köln-Ehrenfeld (wikidata entity), and Köln-Mülheim (wikidata entity) all deliver the same geo coordinates though they have different ones in wikidata.
This looks like a mismatch in the local buffer. I'm gonna investigate it.
Is the query template I provided in hbz/nwbib#83 (comment) actually used here: https://www.wikidata.org/w/api.php?action=query&list=search&format=json&srsearch=$place_name ?
Yes, this is step 1 of the 2-step wikidata query. Step 2 is like: https://www.wikidata.org/wiki/Special:EntityData/my_id.json
So how do you want the result to look like then?
I suggest something like this, taking the label from labels.de.value
:
{
"id": "Q897382",
"label": "Köln-Ehrenfeld",
"latitude": 50.9464,
"longitude": 6.91833
}
Nothing has changed, nothing to review. Unassigning myself.
...and moving to Ready
as @philboeselager won't have time to work on this until the end of January.
Since our workshop didn't last until eob today, I can deploy that now.
Deployed now on server. But not working for search terms with special chars (umlauts), see #35.
+1
Can this be closed now?
As we don't have a staging server yet for geodata (will be implemented with #34) this is already on production. Closing.
(We might have to adjust the JSON a bit when working on #27.)
Coming from https://github.com/hbz/nwbib/issues/83 , we need an additional query technique, collecting geo data from Wikidata.