uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luca Foppiano <l...@foppiano.org>
Subject uima-fit and uima annotators (in my case Whitespace annotator)
Date Thu, 23 Jan 2014 08:21:53 GMT
Hi Everybody,
    I'm starting playing with uima-fit and I'm trying to integrate the
whitespace annotator into my simple pipeline composed by a collection
reader a simple AE (plays with the text, doesn't annotate) and I want to
add a whitespace annotator to be applied to the text.

I've download the trunk version of the Whitespace annotator on github, I've
extracted the type system definition from the descriptor XML and referenced
it from uimafit. The pipeline worked without crashing.

Now I want to add an AE that takes the annotations and do something with
that (print them for example).

I could not find a way to work around the fact the type system java class
were not present in the project, is this a mandatory requirement?

What I've tried is to do something like:

//Get the type autogeneated type system (SentenceAnnotation,
TokenAnnotation)
TypeDescription[] types = tsd.getTypes();

[...]
//..and try to pass them to my annotator
        AnalysisEngineDescription casConsumer =
AnalysisEngineFactory.createEngineDescription(SimpleCC.class,
                SimpleCC.OUTPUT_DIR_PARAM,
                "/home/lf84914/development/epo/apl/data/out",
*                types, null*);

but then, in the AE's code, I have no idea how to use them.

Any suggestions?

Thank everybody in advance.
-- 
Luca Foppiano

Software Engineer
+31615253280
luca@foppiano.org
www.foppiano.org

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message