Hi Stardog team,
Suppose that I have some instances having different rdfs labels.
insert{
http://test.com/TEST16 rdfs:Label "username" .
http://test.com/TEST17 rdfs:Label "user_name" .
http://test.com/TEST18 rdfs:Label "user-name" .
http://test.com/TEST19 rdfs:Label "user" .
}
where {}
What I need to do is retrieving all instances using textMatch in the order of text similarity score.
But the following query gives only "user-name" and "user" with the same score as below.
select *
where {
?s rdfs:Label ?o .
(?o ?score) tag:stardog:api:property:textMatch ("user~" 0 100).
}
s | o | score |
---|---|---|
:TEST18 | user-name | 2.54044508934021 |
:TEST19 | user | 2.54044508934021 |
So I put wildcard *
select *
where {
?s rdfs:Label ?o .
(?o ?score) tag:stardog:api:property:textMatch ("user*~" 0 100).
}
and now it gives all of them with the same score.
s | o | score |
---|---|---|
:TEST16 | username | 1.0 |
:TEST17 | user_name | 1.0 |
:TEST18 | user-name | 1.0 |
:TEST19 | user | 1.0 |
Can you provide a proper way to differentiate them with different scores?
Thank you in advance.