You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Peter Klügl (JIRA)" <de...@uima.apache.org> on 2013/08/16 18:18:48 UTC
[jira] [Commented] (UIMA-3191) Quantifier on composed rule is
ignored
[ https://issues.apache.org/jira/browse/UIMA-3191?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13742349#comment-13742349 ]
Peter Klügl commented on UIMA-3191:
-----------------------------------
I will take a look at it.
Just a short comment about your rules (using ruta-2.0.2 stuff).
Your FILTERTYPE rule will not revert the changes by your RETAINTYPE rule. I know that is a bit counterintuitive (it has historical reasons). You should probably use a last rule like {{Document{->RETAINTYPE};}} in order to restore the default settings of the ae.
Your current Id rule will create multiple overlapping annoations. A {{-PARTOF}} or {{MARKONCE}} would avoid that.
Until I found and fixed the problem you could probably use a rule like
{noformat}
(CW | NUM | SPECIAL{REGEXP("-")})+{-PARTOF(Id) -> Id};
{noformat}
> Quantifier on composed rule is ignored
> --------------------------------------
>
> Key: UIMA-3191
> URL: https://issues.apache.org/jira/browse/UIMA-3191
> Project: UIMA
> Issue Type: Bug
> Components: ruta
> Reporter: Alexandre Patry
>
> I wrote the following script and expected it to match strings like "A1A-1A1-A1A" :
> {code}
> DECLARE Id;
> Document{->RETAINTYPE(WS)};
> (NUM | CW)+{-> MARK(Id, 1, 2)} (SPECIAL{REGEXP("-")} (NUM | CW)+)+;
> Document{->FILTERTYPE(WS)};
> {code}
> When I ran it through the workbench (version 2.0.1), all matches contained at most one dash like if the last PLUS-GREEDY is ignored.
> I also tried to run a similar script with the trunk version of the workbench and had similar results.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira