Refactor default presets, fix chardet version conflict, improve welcome banner refresh logic

- Rename presets: "Efficiency" → "Max Power", "Intelligence" → "Balance", add "Cost Efficient" - Update preset models: use Claude Opus 4.6, Sonnet 4.6, Kimi K2.5, GPT-5.4-mini/nano, Gemini 3.1 Flash Lite - Adjust context lengths and vision capabilities across presets - Pin chardet<6 to avoid import warnings from requests when unstructured is installed - Replace settings-updated listener with modal-closed event

frdel committed Mar 24, 2026 at 19:17 UTC 986c1b1cee7f47417758d989517d8fa58528b887
4 files changed +41 -11
plugins/_model_config/default_presets.yaml
+23 -7
@@ -1,31 +1,47 @@
1 -- name: "Efficiency"
1 +- name: "Max Power"
2 chat:
3 provider: "openrouter"
4 - name: "openai/gpt-5.2-chat"
4 + name: "anthropic/claude-opus-4.6"
5 + api_key: ""
6 + api_base: ""
7 + ctx_length: 200000
8 + ctx_history: 0.7
9 + vision: true
10 + utility:
11 + provider: "openrouter"
12 + name: "openai/gpt-5.4-mini"
13 api_key: ""
14 api_base: ""
15 ctx_length: 128000
16 + ctx_input: 0.7
17 +- name: "Balance"
18 + chat:
19 + provider: "openrouter"
20 + name: "anthropic/claude-sonnet-4.6"
21 + api_key: ""
22 + api_base: ""
23 + ctx_length: 200000
24 ctx_history: 0.7
25 vision: true
26 utility:
27 provider: "openrouter"
12 - name: "openai/gpt-5-nano"
28 + name: "google/gemini-3.1-flash-lite-preview"
29 api_key: ""
30 api_base: ""
31 ctx_length: 128000
32 ctx_input: 0.7
17 -- name: "Intelligence"
33 +- name: "Cost Efficient"
34 chat:
35 provider: "openrouter"
20 - name: "anthropic/claude-opus-4.6"
36 + name: "moonshotai/kimi-k2.5"
37 api_key: ""
38 api_base: ""
39 ctx_length: 128000
40 ctx_history: 0.7
25 - vision: true
41 + vision: false
42 utility:
43 provider: "openrouter"
28 - name: "google/gemini-3-flash-preview"
44 + name: "openai/gpt-5.4-nano"
45 api_key: ""
46 api_base: ""
47 ctx_length: 128000
requirements2.txt
+4 -1
@@ -1,2 +1,5 @@
1 litellm==1.79.3
2 -openai==1.99.5
\ No newline at end of file
2 +openai==1.99.5
3 +# `unstructured` pulls `chardet` without an upper bound, but `requests`
4 +# warns on import when chardet>=6 is present in the same environment.
5 +chardet<6
webui/components/welcome/welcome-store.js
+5 -3
@@ -18,9 +18,11 @@ const model = {
18 },
19
20 init() {
21 - // Reload banners when settings change
22 - document.addEventListener("settings-updated", () => {
23 - this.refreshBanners(true);
21 + // Reload banners when a modal closes while the welcome screen is visible.
22 + document.addEventListener("modal-closed", () => {
23 + if (this.isVisible) {
24 + this.refreshBanners(true);
25 + }
26 });
27 },
28
webui/js/modals.js
+9
@@ -306,6 +306,15 @@ export async function closeModal(modalPath = null) {
306 restoreModalScrollSnapshot(modalStack[modalStack.length - 1]);
307 }
308
309 + document.dispatchEvent(
310 + new CustomEvent("modal-closed", {
311 + detail: {
312 + modalPath: modal.path ?? null,
313 + remainingModalCount: modalStack.length,
314 + },
315 + }),
316 + );
317 +
318 return true;
319 });
320 }