change(web): change "correction search" into "suggestion search"
- Dominant language
- Pascal
- Stars
- 534
- Forks
- 143
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 113
Description
Currently, our predictive-text engine operates by searching for the next best available text _correction_, then seeing what words may be _predicted_ from that. Note - the search optimizes solely by the _correction cost_, and we build predictions off of that.
However, our correction-search objects actively track the `LexiconTraversal` corresponding to their represented correction. That same object can be used as a _very_ informed guess for the maximum _suggestion_ probability for its corresponding correction. If we were to include this in the criteria used for correction-search, we could better prioritize cases where the predicted word is likely despite higher-cost corrections - such as with transpositions.
This could allow us to improve our correction-cost threshold loosening, wasting less time and energy on searches in certain cases. In particular, this would let us reverse a change made in #16450 that lowered the threshold due to the "correction search" limitation - "teh" wasn't being corrected due to an overly strict threshold - one that could not be mitigated by "the"'s high word frequency.
Contributor guide
Research direction
Start by locating the correction-search objects and the LexiconTraversal they track in the predictive-text engine. Trace how correction cost currently orders searches and how suggestion probability could influence that ordering. Done means the search prioritizes likely suggestions, improves cases such as "teh" to "the," and allows the threshold change from #16450 to be reconsidered.
Written by the indexing model from the issue text.
Assessment
- Domain
- search, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100