Skip to content

Keep keyboard predictions stable during scanning - #806

Merged
enaboapps merged 1 commit into
mainfrom
codex/prediction-stability-805
Sep 20, 2026
Merged

enaboapps merged 1 commit into
mainfrom
codex/prediction-stability-805

Conversation

@enaboapps

@enaboapps enaboapps commented Sep 20, 2026 •

Copy link
Copy Markdown
Contributor

When native text reading works but fallback input tracking is unavailable, prediction polling repeatedly reset the cached batch. The scanning keyboard then treated unchanged suggestions as replacements and cleared them while their row was active.

Preserve native context caching independently of fallback tracking. Keep genuine edits, focus/caret/selection changes, explicit resets and stale acceptance invalidating old choices. Input-observer failure still disables tracked-text fallback.

Validation:

  • Required frontend lint, 158 frontend tests, 5 script tests and build pass locally.
  • Rust format, Clippy and full tests pass: 477 unit tests and 7 configuration tests; one existing ignored benchmark.
  • Added worker/service regressions for unavailable tracking with native reads, genuine changes yielding identical words, editing/casing/selection, and pending resets.
  • Added grouped/linear, forward/reverse, manual/automatic scanning regressions for unchanged replies, timing, pass limits and exactly-once selection.
  • Independent latest-head review is clean on 7928e603857adc0139816df9358d1eddfa08c158.
  • Mac VM: development-signed build launched; J/K/L navigated the action menu and keyboard, and selected Space and W each typed once in disposable TextEdit content with focus preserved. Predictions remained empty, so suggestion stability could not be qualified natively. Supplied the debug build's database at its compile-time resource path for the test; removed that temporary resource afterward.
  • Windows ARM VM: native build succeeded. Parallels virtual Insert/F1 switches navigated the menu to Type here; the keyboard did not become visible and later switch presses produced no observable scan movement. This matches the previously documented VM qualification limitation; no root cause or product regression is asserted.
  • VM settings restored byte-for-byte, test app/editor stopped, previous Windows build restarted, and Mac returned to suspended. The signed host Mac app (PID 55560) remained untouched.
  • All required CI checks pass on 7928e60, including native Mac and Windows packaging, dependency audit and CodeQL. The unchanged frontend setup-dialog test timed out on the initial run; the failed-job rerun passed (run 35518638988, attempt 2).

Keep draft: native suggestion stability still requires qualification on both VMs.

No settings or BLE changes. No merge or release requested.

Closes #805.

Separate fallback tracking availability from native context caching and stop unchanged polls from resetting prediction batches. Cover scan timing, pass limits, selected choices and stale-context rejection.
@enaboapps
enaboapps marked this pull request as ready for review September 20, 2026 16:13
@enaboapps
enaboapps merged commit 997b96e into main Sep 20, 2026
9 of 10 checks passed
@enaboapps
enaboapps deleted the codex/prediction-stability-805 branch September 22, 2026 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Keep keyboard predictions stable during scanning

1 participant