uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From swirl <swirl...@yahoo.com>
Subject Using uima pipeline as an API
Date Thu, 18 Jul 2013 07:22:29 GMT
Hi,

I have this particular requirement for a API that we wrap over a Uima 
pipeline.

 public List<String> analyse(String inputFolderPath, String modelName);

This method is supposed to accept a collection of files (residing in the 
inputFolderPath), run the files (as CAS) through a pipeline of UIMA AEs, and 
return the results (one String per CAS).

To return the strings, I will need to somehow access the CAS after the AEs 
have finished their job and transform/extract whatever inside the CAS into 
the string that I will return to the caller of this method.

But if I run the AEs using a SimplePipeline.runPipeline()
How I can get hold of the CAS that are coming out of the AEs?
Do I attach a CAS Consumer at the tail of the pipeline and read the CAS 
contents at that point? Then I append each result to the List<String> that I 
constructed at the begining.

If so, is this scalable? 
If I have thousands of files in the inputFolderPath, and if the strings are 
very large, would I run out of memory soon?
Is there a more scalable way to do this?



Mime
View raw message