-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Open
Description
Hi,
I just encountered this error while trying the tokensregex syntax at http://corenlp.run/
- Version 4.4.0
- Example of a working pattern:
the very* first? day of the tentacle

- Example of a failing pattern:
the very* first? day+ of the tentacle

It seems that the + character is escaped as \+ at some point of the process (see the error screenshot).
If I try the pattern the very* first? day{1,} of the tentacle, it works as expected.
I also tried to parse the same pattern with the CoreNLP Java library in version 4.4.0, and it works without error with the "+" operator.
String strPattern = "the very* first? day+ of the tentacle";
TokenSequenceParser parser = new TokenSequenceParser();
Env env = new Env(parser);
env.initDefaultBindings();
Pair<PatternExpr, SequenceMatchAction<CoreMap>> p = parser.parseSequenceWithAction(env, strPattern);
// => works without error !I don't know if the problem is just present on the http://corenlp.run/ online tester, or in a Java lib that I haven't tried.
Metadata
Metadata
Assignees
Labels
No labels