Large learned-word dictionaries cause noticeable swipe/prediction lag

App Store Released Performance, freezes & crashes Normal

unplugged TESTER · iOS 27 · iPhone Air ·

Steps to reproduce

  1. Import a large word list into learned words (around 30,000 words).
  2. Use swipe/glide typing normally.
  3. Observe the delay before EFKey chooses/inserts the swiped word.
  4. Sometimes there is also an additional delay after tapping one of the suggested words.

What I expected

Swipe recognition and selecting suggestions should remain responsive with a reasonably large learned-word dictionary.

What happened instead

After importing approximately 30,000 words, EFKey becomes noticeably slower. After swiping a word, it can take around 1-2 seconds before the recognized word is inserted. Sometimes tapping a suggested candidate also causes an additional delay of about one second.

Is 30,000 words currently an intended/recommended limit for learned words? If so, could the limit be increased or lookup performance optimized for larger dictionaries?

Discussion

Nikhil.tom TESTER ·

Yes this happened in the initial versions, haven’t tested with the latest versions.

efko DEV ·
status → Open
efko DEV ·

hey @unplugged, found it. at that size the keyboard kept rebuilding its internal word index every time you learned a new word, and that rebuild briefly froze input while it ran. that's the 1-2s before a swiped word lands, and the pause after tapping a suggestion. the lookups themselves were fast, it was the rebuild sitting in the way. i moved it off the path swipe and the suggestion bar actually use, so it stays responsive at 30k now.

30k is the current cap for learned words, but the slowness you hit wasn't really about the count, it was that rebuild. raising the cap is a separate thing i'm looking at. the lag at 30k is the part that's fixed, and it's in build 409.

when 409 lands, could you try it again with your full list? if you still get any delay right after tapping a suggestion, tell me. that specific path has one more corner i want to measure.

unplugged TESTER ·

Awesome, thank you for digging into this and finding the actual cause! Really appreciate the quick fix and the detailed explanation of what was happening.

I’ll definitely test it with my full 30k list as soon as it lands and report back if I notice anything.

Thanks again!

efko DEV ·
status → Needs testing
efko DEV ·

@unplugged done?

unplugged TESTER ·

@efko yes, fixed, very smooth now!

efko DEV ·
status → Fixed

Sign in to comment or vote.