I am looking to create an index called 'story' in Elasticsearch. This index will store multiple documents, each containing a field called 'description' which provides some information about the story represented by the document. My objective is to enable term-based subsequence search queries.
For instance:
Doc1 = {
description = "A quick brown fox jumps over a lazy dog"
}
Doc2 = {
description = "The fox is very agile and quick"
}
If a user inputs ['fox', 'quick'], only Doc2 should be matched, excluding Doc1. Essentially, this involves wildcard queries but applied to terms, such as 'term1 * term2 * term3'.
Is it feasible to implement this in Elasticsearch?
The only approaches I could think of involve replacing all whitespace and other delimiting characters with some other symbol, so that each description becomes a single term. Then, I would perform standard wildcard queries on them. However, given that the description could be quite large, I'm unsure if this is a desirable approach.