You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@uima.apache.org by Ar...@bka.bund.de on 2013/05/08 08:42:39 UTC
Textmarker/Ruta - negative look behind/ahead
Hello!
Is there a mechanism like negative look behind or negative look ahead in Ruta?
Cheers,
Armin
Re: Textmarker/Ruta - negative look behind/ahead
Posted by Peter Klügl <pk...@uni-wuerzburg.de>.
Hi,
no, there is no direct negative match support (actually, there has been
one, but it was removed).
What you can do is just use the positive matches with additional
conditions, e.g., something like:
Person ANY{-STARTSWITH(Org)}; // additional rule element
Person{-NEAR(Org, 0, 4, true)}; // with additional condition
Person{-NEAR(Org, 0, 4, false)}; // with additional condition
A negative lookahead with an additional rule element is a bit more
complicated because of the matching strategy. You could activate dynamic
anchoring in order to avoid inefficient matches.
Document{-> DYNAMICANCHORING(true)};
ANY{-ENDSWITH(Org)} Person ; // additional rule element
I hope this helps. Just let me know if I misinterpreted your question.
Best,
Peter
On 08.05.2013 08:42, Armin.Wegner@bka.bund.de wrote:
> Hello!
>
> Is there a mechanism like negative look behind or negative look ahead in Ruta?
>
> Cheers,
> Armin