Topic on Project:Village Pump

Api for concept distances?

2
2601:240:8301:2AD0:1531:AFC0:E208:ED82 (talkcontribs)

Is there something a [directional?] notion/implementation of distance between Wikipedia categories/pages? For example consider: A) "Saint Louis University" B) "university"

Clearly "A" is a type of "B". How can you extract this from Wiki? If you extract all the categories connect to A, you'd see that it gives

Category:1818 establishments in Missouri Territory Category:Articles containing Latin-language text Category:Association of Catholic Colleges and Universities Category:Commons category with local link same as on Wikidata Category:Coordinates on Wikidata Category:Educational institutions established in 1818 Category:Instances of Infobox university using image size Category:Jesuit universities and colleges in the United States Category:Roman Catholic Archdiocese of St. Louis Category:Roman Catholic universities and colleges in Missouri

and it does not contain anything that would directly connect to B (https://en.wikipedia.org/wiki/University). But essentially if you look further, you should be able to find a multi-hop path between A and B, possibly multiple hops.

MarkAHershberger (talkcontribs)

You're looking for WikiData. If you visit Saint Louis University, you'll see a link titled "đź–‰Edit links" that will take you to the WikiData page where you can see that the university is an instance of a university.

As far as distance, I'm sure that you could compute that using WikiData if you wanted.

Reply to "Api for concept distances?"