Hello Alexander,
One way I can recommend is to extend the dataset with some new property,
such that value(s) of this property of a subject are "normalized"
versions of the title, e.g., all lowercase, with and without the
disambiguation part (the part in "(...)" at the end of otherwise
ambiguous title), with swapped first and last name (i.e., to keep both
"van gogh, vincent" and "vincent van gogh", and both lowercase etc.)
Other approach is to not try to compose IRIs from user's input but use
free-text search in values, selecting the IRI with biggest free-text
rank found and probably sorting even more, like
select ?s ?o ?scr where {
?s rdfs:label ?o .
?o bif:contains "gogh" option (score ?scr) .
filter (langmatches(lang(?o), "en"))
}
order by
desc(?scr)
asc (bif:length (str(?o)))
asc(str(iri(?s)))
limit 100
Having sufficient number of customer requests, I can add efficient
search for IRIs by some IRI properties (e.g. free-text on them).
So far, studying each reported use case in depth reveals either some
inaccuracy/incompleteness in ontology or some way of fetching subjects
by their textual properties.
Best Regards,
Ivan Mikhailov
OpenLink Software
http://virtuoso.openlinksw.com
On Sun, 2011-07-03 at 02:39 +0700, Alexander Sidorov wrote:
> Hello!
>
>
> I need to search DbPedia uri by wikipedia link (entered by user). For
> example:
>
>
> SELECT ?uri WHERE
> {
> ?uri foaf:page <http://en.wikipedia.org/wiki/Moon>
> }
>
>
> But I need to make this query case-insensitive (for the case when, for
> example, user enters ".../moon" instead of ".../Moon"). Here is what I
> tried:
>
>
> SELECT ?uri
> WHERE
> {
> ?uri foaf:page ?url
> FILTER regex(str(?url), "^http://en.wikipedia.org/wiki/Moon$", "i")
> }
>
>
> But it is obviously very and very slow. Is there any way to solve this
> task more efficient?
>
>
> Regards,
> Alexander
> ------------------------------------------------------------------------------
> All of the data generated in your IT infrastructure is seriously valuable.
> Why? It contains a definitive record of application performance, security
> threats, fraudulent activity, and more. Splunk takes this data and makes
> sense of it. IT sense. And common sense.
> http://p.sf.net/sfu/splunk-d2d-c2
> _______________________________________________ Virtuoso-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users