Description
Feature request:
Following up on this discussion:
ES 7.0 introduced support for the Lucene intervals
query which is more powerful and easier to deal with than span
queries (analyzer support, etc). However, one thing that span
queries support and intervals
doesn't is fuzziness. Since the intervals
query is supposed to help in legal and patent search, I have a hard time understanding how this could be possible without fuzziness support.
I could not find much information about that when browsing the Github issues. Is there any reason why the intervals
query doesn't support fuzziness? (because Lucene doesn't maybe)? Is it on the roadmap?
Quoting @jimczi who suggested to open a new issue so that this new feature request could be discussed:
I think it's worth opening an issue in Elasticsearch and we'll discuss where the support should land (Elasticsearch or Lucene). As @Mikhail_Khludnev suggested it should be easy to make fuzzy intervals in Elasticsearch using the MultiTermIntervalsSource except that it is not exposed 😉. Queries that need to check positions cannot handle large number of multi-terms so we have some logic to restrict to those that expand to less than a provided threshold (bounded to 1024). With this protection in place I don't see why we should not expose them more simply in Lucene.
The floor is yours, guys!