I have got this working. However, is there any way I can augment the reference data (wikidata, dbpedia) with my own local graphdb content. if I wanted to recognise my own entities, can I add my db to the kwowledge base?
Source:
https://graphdb.ontotext.com/documentation/10.5/text-mining-plugin.html#what-s-in-this-document
Create a TAG client
PREFIX txtm: <http://www.ontotext.com/textmining#>
PREFIX txtm-inst: <http://www.ontotext.com/textmining/instance#>
INSERT DATA {
txtm-inst:tagService txtm:connect txtm:Ces;
txtm:service "https://tag.ontotext.com/extractor-en/extract" .
}
Find Tag entities through GraphDB
PREFIX txtm: <http://www.ontotext.com/textmining#>
PREFIX txtm-inst: <http://www.ontotext.com/textmining/instance#>
PREFIX pubo: <http://ontology.ontotext.com/publishing#>
SELECT ?annotationText ?annotationType ?annotationStart ?annotationEnd ?feature ?value
WHERE {
?searchDocument a txtm-inst:tagService;
txtm:text '''Dyson Ltd. plans to hire 450 people globally, with
more than half the recruits in its headquarters in Singapore.
The company best known for its vacuum cleaners and hand dryers will add 250 engineers in
the city-state. This comes short before the founder James Dyson announced he is moving
back to the UK after moving residency to Singapore. Dyson, a prominent Brexit supporter
who is worth US$29 billion, faced criticism from British lawmakers for relocating his
company.''' .
graph txtm-inst:tagService {
?annotatedDocument txtm:annotations ?annotation .
?annotation txtm:annotationText ?annotationText ;
txtm:annotationType ?annotationType ;
txtm:annotationStart ?annotationStart ;
txtm:annotationEnd ?annotationEnd ;
{
?annotation txtm:features ?item .
?item ?feature ?value
}
}
}