Did you consider using the keyword search (http://wiki.dbpedia.org/Lookup) ?

for example
http://lookup.dbpedia.org/api/search.asmx/KeywordSearch?QueryString=Is%C3%A8re


2014-06-27 13:46 GMT+02:00 Mohammad Ghufran <emghuf...@gmail.com>:

> Hello,
>
> Thank you for your reply. Yes, I tried doing that. If i try to remove the
> accents, i normally get a redirection page in the search results. I can
> then get the resource uri for this result and get the actual resource page.
> However, this only happens sometimes. For example, a region in France
> called Isère has the following page: http://dbpedia.org/page/Is%C3%A8re .
> If i access the page without the accent, I am still redirected to the
> correct page. However, if I search for the plain string in the label, I
> don't get any results. Here is the query I am using:
>
> PREFIX dbpedia-owl: <http://dbpedia.org/ontology/>
> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> SELECT DISTINCT ?place
> WHERE
> {
>     ?place a dbpedia-owl:PopulatedPlace .
>     ?place rdfs:label ?label .
>     FILTER (str(?label)= "Isere") .
> }
>
> The language is not known a-priori, as i said in my earlier message. I am
> trying to make my code language independent. So I cannot use the language.
>
> What is interesting is the fact that dbpedia itself redirects the url
> http://dbpedia.org/page/Isere to http://dbpedia.org/page/Is%C3%A8re . I
> am wondering how this "magic" is done.
>
> Mohammad Ghufran
>
>
> On Fri, Jun 27, 2014 at 1:08 PM, Romain Beaumont <romain.r...@gmail.com>
> wrote:
>
>> Hello,
>> I think you are going to do some preprocessing. For example to handle
>> accents, you can just remove them (in your program/script/...) before
>> transforming it to sparql.
>> Some labels are present in different languages in DBpedia, maybe you
>> could use that ?
>>
>>
>>
>> 2014-06-27 10:57 GMT+02:00 Mohammad Ghufran <emghuf...@gmail.com>:
>>
>>> Hello,
>>>
>>> I am using dbpedia to work with locations in order to compare them and
>>> determine if two locations are same / similar and to what extent. Since my
>>> data source can be user input, the data normally does not match the exact
>>> resource / label defined in dbpedia.
>>>
>>> I am using the sparql endpoint for this (right now, i am using the
>>> dbpedia endpoint but i intend to use a local mirror at a later stage).
>>>
>>> I am looking to address this but still haven't found a good way to do
>>> so. I give an example here to elaborate. Take for example the
>>> region Rhône-Alpes in France. If i search for Rhone-Alpes in the label, i
>>> don't see any results. Neither in the disambiguation pages or even through
>>> the keyword search (Lookup) api.
>>>
>>> Is there a way to address this issue? I want to query such that i get
>>> the page Rhône-Alpes as one of the results when i search for Rhone-Alpes
>>> for example. This also extends to labels in different languages. My input
>>> does not specify the language so the input might be in different languages.
>>> For instance, Italia, Italy, Italie all refer to the country Italy in
>>> different languages.
>>>
>>> Thank you for any suggestions / help in advance.
>>>
>>> Best Regards,
>>> Ghufran
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Open source business process management suite built on Java and Eclipse
>>> Turn processes into business applications with Bonita BPM Community
>>> Edition
>>> Quickly connect people, data, and systems into organized workflows
>>> Winner of BOSSIE, CODIE, OW2 and Gartner awards
>>> http://p.sf.net/sfu/Bonitasoft
>>> _______________________________________________
>>> Dbpedia-discussion mailing list
>>> Dbpedia-discussion@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/dbpedia-discussion
>>>
>>>
>>
>
------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
Dbpedia-discussion mailing list
Dbpedia-discussion@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dbpedia-discussion

Reply via email to