I'm looking for a solution to search for strings in a large text file. I would like to match strings with as many of those words in close proximity as possible.
For example, if a query is for the string "what is the term for a supreme court justice"
- "a supreme court justice has lifetime tenure, meaning"
- "the term of justice in the supreme court is.."
Would be matches in they are in the document being searched.
I'm sure that algorithms for this type of searching already exist, but I don't know what they are called or exactly what it is that I'm looking for.