I am trying to retrieve from Dbnary database based on dbpedia all words belongigs to categorie of noun, adjectif, adverb and verb and their synonyms.
So far I get can access it just for one categorie but I would like to know how to improve my query to get all words from the 4 categories and their synonym with only one query rather than making one query per category (i.e 4 query and 4 files)
#Query for noun which work
SELECT DISTINCT * where {
?l a ontolex:LexicalEntry;
lime:language "fr";
ontolex:canonicalForm ?f ;
lexinfo:partOfSpeech lexinfo:noun ;
ontolex:sense ?s .
?f ontolex:writtenRep ?w .
OPTIONAL { ?l dbnary:synonym ?syn ; rdfs:label ?synonyme .}
}
LIMIT 100
This query work , you can test it since dbnary in online : http://kaiko.getalp.org/sparql
but I wanted to upgrade the query below. When adding the following line on the previous query, it does not work :
#lexinfo:partOfSpeech lexinfo:verb ;
Any help will be fine.