The switcher raised its loading flag on every refresh, so the chat or agent profile switch unmounted the whole selector button and the label flashed away until the fresh state arrived. Raise the flag only on the first load when no presets are known yet and let background refreshes replace selector state in place under the existing sequence guards.
Validation: pytest tests/test_chat_loading_refresh.py (12 passed, new regression fails without the fix) and node --check on the mixin on the framework runtime.
Run model/profile, context-usage and goal display refreshes independently
of snapshot rendering so chat switches do not wait for their API calls.
Guard refreshes and save completions by request sequence and selected chat.
Pending saves still finish for their original chat, while late responses
cannot replace the current selector state or finish a newer loading cycle.
Add deterministic pending-request and save-race regressions and update
the owning plugin contracts.
Validation: 94 focused tests passed for the loading change, followed by
47 focused tests after the model/profile race fixes. Live checks at
localhost:32081 covered delayed API responses, rapid chat switching,
late profile/preset/clear saves, and desktop/mobile behavior.