Hi @ostephens
Could I ask you about Exercise 5 in that document? I have used the GREL expression there to return People, Places, Companies, Buildings etc and it has been great.
I have been trying to modify the expression to return the spots for annotations where there is no type so that it returns the spots for Dandelion results like this;
{
"time": 1,
"annotations": [{
"start": 11,
"end": 27,
"spot": "Grand Canal Dock",
"confidence": 0.8609,
"id": 10425918,
"title": "Grand Canal Dock",
"uri": "http://en.wikipedia.org/wiki/Grand_Canal_Dock",
"abstract": "The west inner basin and Boland\u0027s Mill, January 2022View of the western (inner) basin from the top floor of the Google Docks (Montevetro) building. Boland\u0027s Mill, the Alto Vetro building, and The Marker Hotel can be seen.Grand Canal Dock is a Southside area near the city centre of Dublin, Ireland. It is located on the border of eastern Dublin 2 and the westernmost part of Ringsend in Dublin 4, surrounding the Grand Canal Docks, an enclosed harbour where the Grand Canal comes to the River Liffey. The area has undergone significant redevelopment since 2000, as part of the Dublin Docklands area redevelopment project.",
"label": "Grand Canal Dock",
"categories": ["Dublin Docklands", "Office buildings in the Republic of Ireland", "Places in Dublin (city)", "Ringsend", "Skyscrapers in the Republic of Ireland"],
"types": [],
"lod": {
"dbpedia": "http://dbpedia.org/resource/Grand_Canal_Dock",
"wikipedia": "http://en.wikipedia.org/wiki/Grand_Canal_Dock"
}
}],
"lang": "en",
"timestamp": "2022-12-06T14:49:58.182"
}
But to to avail. I have tried variations on leaving the types entry empty
forEach(filter(value.parseJson().get("annotations"),a,a.get("types").inArray("")),p,p.get("spot"))
or using not(inArray("http://dbpedia.org/")
but haven’t managed to get anything to work.
Would you have any suggestions on what might succeed?