0

As recently I am trying to query the pagerank scores on DBpedia SPARQL endpoint. For example, the query below is the SPARQL query on DBpedia for retrieving top-10 scientists and ordered by PageRank(can be executed at [http://dbpedia.org/sparql]

PREFIX v:<http://purl.org/voc/vrank#>

SELECT ?e ?r
FROM <http://dbpedia.org>
FROM <http://people.aifb.kit.edu/ath/#DBpedia_PageRank>
WHERE {
?e rdf:type dbo:Scientist;
v:hasRank/v:rankValue ?r.
} ORDER BY DESC(?r) LIMIT 10

I used to query some nodes related to the word: Machine Learning. And I pick out some results below:

http://dbpedia.org/page/Evolutionary_algorithms
http://dbpedia.org/page/Artificial_neural_networks
http://dbpedia.org/page/Markov_models
http://dbpedia.org/page/Cluster_analysis

My first question is : How to retrieve those nodes' pagerank scores on DBpedia SPARQL endpoint? I will be glad if anyone can provide me some query examples.

My second question is : The version of the DBpedia PageRank scores included in the official DBpedia SPARQL endpoint is still 2015-04? Since I can not find out any information about the version.

Thank you very much in advance!

BBQ
  • 23
  • 4
  • the query is `PREFIX v: SELECT ?e ?r FROM FROM WHERE { VALUES ?e { } ?e v:hasRank/v:rankValue ?r. } ORDER BY DESC(?r)` – UninformedUser Nov 25 '20 at 07:07
  • and yes, the data is most likely outdated. – UninformedUser Nov 25 '20 at 07:08
  • Now my question, why did you stop with your previous attempt to compute the page rank? I mean, you're working now on the project for what, 6 month? Where is the problem to compute the pagerank? You can also take the latest DBpedia dump and compute new page rank values. I mean, the whole project source code is even online: https://github.com/athalhammer/danker/#DBpedia_PageRank – UninformedUser Nov 25 '20 at 07:10
  • Thank you so much! I am not stop my work. I need these pagerank scores to compare with the value calculated by my regulated query pagerank scores by Spearman correlation coefficient. – BBQ Nov 25 '20 at 07:21
  • My project is aim to recommend those semantic-related concepts to learners. – BBQ Nov 25 '20 at 07:22
  • Then check the link and recompute the latest pagerank values – UninformedUser Nov 25 '20 at 07:30
  • 1
    I am so appreciated that you help me a lot during the whole process! You are right, the the data is most likely outdated. I will recompute the latest pagerank values for the comparison between my regulated query pagerank scores – BBQ Nov 25 '20 at 07:32
  • I computed the pagerank scores for my regulated query using a python package named networkx. The format of my query results is in ttl format:```print(g.serialize(format='ttl').decode('u8'))``` And I converted it to a directed graph for the networkx pagerank calculation:```dg = rdflib_to_networkx_graph(g, False, edge_attrs=lambda s,p,o:{})``` How can I convert those format to .links in order to fit the format requirement of Danker? – BBQ Nov 25 '20 at 10:06
  • not sure what you are asking for. Danker computes the pagerank on Wikipedia dumps. If you are not able to use such a tool, just take the latest computed and uploaded dump: https://danker.s3.amazonaws.com/index.html - then you can compare the values with your values – UninformedUser Nov 25 '20 at 10:17
  • @UninformedUser Thank you so much! I try to compute the graph of my query result using danker. But it seems not important at all. I will use the latest computed and uploaded dump to process the comparison. – BBQ Nov 25 '20 at 10:24
  • @UninformedUser I eventually got time to continue the project!(I am a secondary school teacher in HK). I forgot to ask you that how can I access the pagerank value that danker calculated? For the DBpedia endpoint, I can use the query you teach me above to find out all the pagerank value that I need. I try to google it, but cannot find out the solution. Thank you in advanced!!! – BBQ Dec 08 '20 at 11:50
  • @UninformedUser Thank you very much! I can access the pagerank value that danker calculated via the Wikidata Q-ID. – BBQ Dec 17 '20 at 14:55

0 Answers0