Thank you all for the fast reply. We also enrich wikidata-items but in our particular use case they are not that helpful. We want to enrich our data semantically using the categories given to Wikipedia articles. Unluckily these category pages have no quivalent in wikidata (e.g. "Category:German poets" [1] is attributed to Goethe). Therefore, we need to collect those category pages directly from Wikipedia and so need a persistent URI from there.
Using the mediawiki API in the form of [2] it is easy to extract the page ID for various category pages. [1] https://en.wikipedia.org/wiki/Category:German_poets [2] https://en.wikipedia.org/w/api.php?action=query&generator=categories&titles=Johann%20Wolfgang%20von%20Goethe&prop=info Am Dienstag, den 14.04.2020, 13:38 +0100 schrieb Andy Mabbett: > > Better still would be to use the Wikidata URI instead: > > https://www.wikidata.org/entity/Q5879 > > with more human-readable equivalent at: > > https://www.wikidata.org/wiki/Q5879 > > You could if you wish simply store the UID, "Q5879". > > Given one of the above, the Wikidata API will always return the > current Wikipedia URI, in German or any other preferred (or other > available, as a fallback) language. > -- Tom Schilling Projektkoordinator EFRE-Projekt "Linked Open Data" Sächsische Landesbibliothek – Staats- und Universitätsbibliothek Dresden (SLUB) Abteilung 2, Referat 2,2 01054 Dresden Besucheradresse: Zellescher Weg 18, 01069 Dresden Tel.: +49 351 4677 474 E-Mail: [email protected] _______________________________________________ Libraries mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/libraries
