Skip to content

Debounce/coalesce contextual user model saves #846

Description

@tianjianjiang

Follow-up to #781.

saveContextualUserModel runs after every observed candidate selection. The write is already off the main thread (snapshot via serialize(), atomic write on a serial queue), so there is no UI impact, but a fast typist still produces one full-file write per selection.

Coalesce saves: e.g. mark dirty and flush after a short idle interval, on deactivation, and at termination. Must not lose the final state on abnormal exit more than the current behavior does.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions