Hi Erik,
it depends on how you want to represent the information of the ids of the covered Person annotations. You somehow need to represent the values in the PersonEnumeration annotation. I assume that the ID feature of Person is uima.cas.String? PersonEnumeration could either use one String Feature, a StringArray feature or a FSArray feature (pointing to the Person annotation which provide the IDs). Here are two examples: PACKAGE uima.ruta; // mock types DECLARE CC, EnumCC; DECLARE Person (STRING id); DECLARE PersonEnumeration (FSArray persons); // mock annotations "Trump" -> Person ("id" = "1"); "Biden" -> Person ("id" = "2"); "and" -> CC; COMMA? @CC{-> EnumCC}; // identify enum span (Person (COMMA Person)* EnumCC Person){-> PersonEnumeration}; // collect all covered Persons pe:PersonEnumeration{-> pe.persons = Person}; ######################## ######################## PACKAGE uima.ruta; // mock types DECLARE CC, EnumCC; DECLARE Person (STRING id); DECLARE PersonEnumeration (StringArray personIds); // mock annotations "Trump" -> Person ("id" = "1"); "Biden" -> Person ("id" = "2"); "and" -> CC; COMMA? @CC{-> EnumCC}; // identify enum span (Person (COMMA Person)* EnumCC Person){-> PersonEnumeration}; // collect ids of all covered Persons using an extra list STRINGLIST ids; pe:PersonEnumeration{-> pe.personIds = ids} <-{p:Person{-> ADD(ids,p.id)};}; Best, Peter Am 06.01.2021 um 08:29 schrieb Erik Fäßler: > Hello everyone (and a happy new year :-)), > > I have been working on the following issue: Whenever there is conjunction in > text of two entities (e.g. [...]Biden and Trump ran for president […]) I > create a new annotation spanning both entities and the conjunction ([Biden > and Trump]_coordination). I can do this fine. > However, my entities - Biden and Trump - also have the ID feature. The new > annotation should receive both IDs from the Biden and Trump annotations. But > I couldn’t manage to do this. > > I have rules like this: > > (Person ( > ",” (Person) > ","? PennBioIEPOSTag.value=="CC" > Person > ) {->MARK(PersonEnumeration)}; > > So an enumeration of Persons are covered with a new annotation of type > “PersonEnumeration”. And now “PersonEnumeration” should receive all the ID > features from the covered Person annotations. How can I do this? > > Best, > > Erik -- Dr. Peter Klügl Head of Text Mining/Machine Learning Averbis GmbH Salzstr. 15 79098 Freiburg Germany Fon: +49 761 708 394 0 Fax: +49 761 708 394 10 Email: peter.klu...@averbis.com Web: https://averbis.com Headquarters: Freiburg im Breisgau Register Court: Amtsgericht Freiburg im Breisgau, HRB 701080 Managing Directors: Dr. med. Philipp Daumke, Dr. Kornél Markó