0

The examples in the documentation suggest that I set the SPARQL endpoint in the following way:

sparql = SPARQLWrapper("http://dbpedia.org/sparql")

Is there any way I can use SPARQLwrapper to search through a local copy of DBPedia rdf dataset?

  • 2
    "SPARQLWrapper is a wrapper around a SPARQL service". That means, you have to provide the service, e.g. load it into your local triple store. – UninformedUser Apr 08 '16 at 12:21
  • Like @AKSW said, just load the data into a local service, and then point SPARQLwrapper at it. You could use Jena's Fuseki, Virtuoso, etc. – Joshua Taylor Apr 08 '16 at 17:08

1 Answers1

0

The argument of the SPARQLWrapper() call is not DBpedia, per se (even though it may look like it), but a SPARQL endpoint.

Change http://dbpedia.org/sparql to your local SPARQL endpoint, e.g., http://local-dbpedia.example.com/sparql ... and you should be set.

sparql = SPARQLWrapper("http://local-dbpedia.example.com/sparql")
TallTed
  • 9,069
  • 2
  • 22
  • 37