-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dependency Matcher ignore OP for negation #12926
Comments
Hi! To better understand what is happening, it's helpful to change the printing of the matches so that they show which exact string was matched for which subpart of the pattern:
Now, let's first define the
As expected, this does not produce any matches on your first (positive) example text, but it will on your second:
Now, you've tried adding
but this is unfortunately not supported and won't change the output. As stated in the docs, only 4 keys are supported: Note that for an unrecognized value (for an existing key) an error will in fact be raised. E.g. when you put Looking at your example code, it appears that you've also tried putting the
In this case, both sentences will match and that's actually not a bug. Look at the output:
What happened is that in both cases, the matcher found a token dependent on the In summary (TLDR):
|
OK. I now understand what happened. Thank you for your quick and professional response. I managed to achieve what I need using the
This way I can enforce that the token before give is not a negation |
Great, thanks for posting this solution to your specific usage example! That'll be useful for others finding this thread :-) |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I wrote a Dependency Matcher pattern, when I demand not to have a Negation Arc from the root.
For some reason, the matcher ignores my request and matched it anyway.
If OP is not supported I would expect to get an Exception not to fail and match.
Your Environment
The text was updated successfully, but these errors were encountered: