You could look at SideEffectCasConsumer.java for an example of outputting delimited files.
Or ParserTreeWriterConsumer.java might be a better place to start, since it outputs a single type. A more complex example, which extracts medication concept codes, would be ConsumeNamedEntityRecordModel.java. But parts of that look like it was written in a hurry -- it doesn’t do a very efficient job of iterating through annotations within other annotations, so I wouldn’t pattern your loops after that. Others might have other suggestions. From: Anirban Chakraborti [mailto:[email protected]] Sent: Wednesday, May 07, 2014 11:24 AM To: Masanz, James J. Subject: Fwd: CEM Template Filler Hi, Not reaching the group so direct email. Feel free to post reply on the group for benefit of all. Thanks, Anirban ---------- Forwarded message ---------- From: Anirban Chakraborti <[email protected]<mailto:[email protected]>> Date: Wed, May 7, 2014 at 9:14 PM Subject: Fwd: CEM Template Filler To: [email protected]<mailto:[email protected]> Thanks again. Would you happen to have a template of CAS consumer which I can customize. What I need is to structure a template so that all medications and downstream concepts, all disease, all anatomical site mentions are grouped together for a particular processed record. Anir On Wed, May 7, 2014 at 12:15 AM, Masanz, James J. <[email protected]<mailto:[email protected]>> wrote: The XXXXXXXMention annotations such DiseaseDisorderMention, SignSymptomMention correspond to the CEMs. You could customize a CAS Consumer to just output the annotations you are interested in, plus the related annotation such as OntologyConcept and UmlsConcept and the MedicationXXXX annotations like MedicationDosage and MedicationDosageModifier. Perhaps we are thinking of different things when we refer to CEMs. What do you mean by CEMs or where did you hear about CEMs? There is also a data normalization pipeline that takes cTAKES output and stores it into a database http://informatics.mayo.edu/sharp/index.php/Data_Normalization But I suspect that is more involved than what you are looking for and I’m not sure if that output is quite what you are looking for either From: Anirban Chakraborti [mailto:[email protected]<mailto:[email protected]>] Sent: Tuesday, May 06, 2014 5:30 AM To: [email protected]<mailto:[email protected]> Subject: CEM Template Filler Hi, I ran Aggregatemplatefiller.xml on a text file and got the attached output in XMI format. How do I convert the same into CEMs supported by Ctakes. The output by itself is very bulky to read. Anir
