-
-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(web): fixes subkey lookup for fat-finger processing #4954
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Please cherry-pick to stable-14.0 😸
Changes in this pull request will be available for download in Keyman version 15.0.33-alpha |
Is this done based on the key position or can we specify the alternate keys/characters in the keyboard definition It would be very useful to define the alternate keys/characters in keyboard. |
This is a fix for the algorithm that tests key distance only. There is no way to specify alternates in Keyman 14. |
Could you give some specific examples where you feel this would perform better than the current approach? Note that lexical model developers can include functionality to assist this: keyman/common/models/types/index.d.ts Lines 122 to 141 in 662e221
For the current keyman/common/models/templates/src/trie-model.ts Lines 50 to 53 in 662e221
Our current approach asserts that the lexical model is a more reasonable location for these decisions to be made, as there are a number of published keyboards that support multiple languages. Some languages may be more "picky" about their alternates. |
Hello @jahorton Here is the discussion we want to be able give list of alternate characters in dictionary for a particular language, which will help correction/suggestion code to look for words in the dictionary. |
If I understand you correctly... it sounds like the simplest solution would be to offer a similar function to the one I mentioned above, but where this one would denote a 'correction' instead of a 'completion'. While not yet offered, this proposal could be used to 'mix in' known correction patterns that don't otherwise arise from neighboring keys. |
On the other hand, I can't help but notice that in your link, the replacements are specified in pairs. Is this similar to the case mentioned here? keyman/common/models/types/index.d.ts Lines 133 to 134 in 662e221
There's no normal If you expect a keyboard for your language to do something similar, and the keys really are that related, |
If we want to pursue the second half of this conversation, we'll need to turn it into a separate issue, otherwise we won't be able to track it! |
Fixes one part of #4953 - from the third screenshot onward.
Turns out that subkeys couldn't be "looked up" during fat-finger alternate computation, so their entries were never available as prediction roots. This is easily fixed by 'namespacing' popup key IDs in order to forward the lookup operation appropriately.