Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
AI OnAI Off
Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
For some reason collapsed code blocks are not shown in my original post (Chrome), so duplicating them here:
The query sent to api by .Filter(x => x.Title.MatchFuzzy(input))
{ "query": { "constant_score": { "filter": { "query": { "fuzzy": { "Title$$string": { "value": "infromation" } } } } } } }
The second test which uses .FuzzyFilter extension is:
[TestCase("excrusion")] [TestCase("excrusio")] [TestCase("excursio")] [TestCase("Piroritized")] [TestCase("piroritized")] [TestCase("prior")] [TestCase("Prioritized")] [TestCase("infromation")] [TestCase("*Piroritized*")] public void Suggest_MatchFuzzy(string input) { var q = Client.Search<InformationIndexModel>() .Filter(x => x.Title.MatchFuzzy(input)) .WithLogToConsole("fuzzy-suggest-epifind-match-fuzzy", input); var result = q.GetResult().ToList().LogTitlesToConsole(); result.Count.Should().BePositive(); }
And finally query sent to api by this extension is:
{ "query": { "fuzzy": { "Title$$string.standard": { "value": "infromation", "boost": 1.0 } } } }
Hi,
I'm trying to utilize fuzzy queries and suggest user correct words when search term typed incorrectly. I built a test index which has words "excursion", "prioritized", and "travel" in the title (the field name in index is "Title$$string") and trying to run the followin tests:
it appears that only 1 query returns non-empty results which looks incorrect. The query sent to api is:
My second attempt was to use an extension similar to http://joelabrahamsson.com/wildcard-queries-with-episerver-find/:
and the test is:
which returns results for all inputs except "excrusio" which is probably correct. The query sent to server is:
Then I tried to play with minSimilarity but the results were the same.
So the question number 1 - is how a correct query should look like?
and question number two is more specific: in the query above (which looks almost good for me) I see "Title$$string.standard" which probably means "standard" analyzer. Are there a quick way to fix it and give me a better control by minSimilarity field?