dkpro-cassis icon indicating copy to clipboard operation
dkpro-cassis copied to clipboard

Add positional predicates

Open reckart opened this issue 5 years ago • 0 comments

Is your feature request related to a problem? Please describe. I think it would be great if the CAS API in cassis would also offer predicates such as "contains" or "overlaps" to check the positional relation between two annotations to each other.

Describe the solution you'd like A solution similar to https://github.com/apache/uima-uimaj/pull/62 which provides these predicates on two places:

  • on annotation types, e.g. to do something like sentence.contains(token)
  • as separate utility methods, e.g. to do something like contains(sentence, token)
  • with different signature, e.g. contains(begin1, end1, begin2, end2), contains(annotation1, begin2, end2), contains(annotation1, annotation2)

reckart avatar Oct 11 '20 16:10 reckart