dsh-thinking-levels 3.4.1 → 3.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/client.js CHANGED
@@ -7,304 +7,695 @@ window.__ModuleLoader__.load({
7
7
  let react = require("react");
8
8
  let react_jsx_runtime = require("react/jsx-runtime");
9
9
  //#region src/client/locales.ts
10
- /** `thinking-levels` client dictionaries (zh / en / ja / ko). */
10
+ /** `thinking-levels` client dictionaries (zh / en / ja / ko / fr / de / it / ru / es). */
11
11
  /** Dictionary namespace owned by this plugin. */
12
12
  const NS = "thinking-levels";
13
- /** Simplified Chinese dictionary (the key-set source of truth). */
14
- const zh = {
15
- "card.title": "思考档位",
16
- "family.title": "起子插件设置",
17
- "card.description": "在模型选择器中可选 Auto(mask):按工具调用历史自动在 low / high / max 间调度后提交 API。此处配置默认档位、调度边界与模型能力(档位 → 网关线上值映射)。",
18
- "card.level": "默认档位",
19
- "card.level.off": "off — 关闭思考(仅手动,永不自动选择)",
20
- "card.level.on": "on — 开启思考(仅 toggle 型模型;只发 enable_thinking,不发 effort)",
21
- "card.level.minimal": "minimal — 最低(极轻任务)",
22
- "card.level.low": "low — 低(简单任务,廉价轮保持廉价)",
23
- "card.level.medium": "medium — 中",
24
- "card.level.high": "high — 高(官方默认)",
25
- "card.level.xhigh": "xhigh — 特高",
26
- "card.level.max": "max — 最大(重任务)",
27
- "card.level.auto": "auto — 按工具历史自动调度(默认)",
28
- "card.enabled": "启用",
29
- "card.allowDowngrade": "允许降档(auto 可降至 low)",
30
- "card.allowUpgrade": "允许升档(auto 可升至 max)",
31
- "card.unavailable": "设置命名空间不可用:请确认 dsh-thinking-levels 已装配进 profile。",
32
- "card.readonly": "只读",
33
- "card.capabilities": "模型能力(llm-pi-ai 自定义提供方)",
34
- "card.capabilities.hint": "直接读写 llm-pi-ai 配置:勾选档位并填写发送给网关的线上值(例如 high → ultra);off 留空表示不发送。视觉决定图片输入;思考开关决定 enable_thinking 置位;thinkingFormat 决定 wire 序列化格式。",
35
- "card.capabilities.empty": "llm-pi-ai 中没有已配置模型的自定义提供方。请先在「设置 → 模型」添加提供方与模型。",
36
- "card.capabilities.unavailable": "llm-pi-ai 设置命名空间不可用。",
37
- "card.capabilities.none": "(无模型)",
38
- "card.capabilities.search": "搜索模型(名称或 ID)…",
39
- "card.capabilities.noMatches": "没有匹配的模型",
40
- "card.capabilities.quickSettings": "一键设置",
41
- "card.capabilities.presetOfficial": "应用到全部:Off / High / Max(官方 DeepSeek 风格)",
42
- "card.capabilities.presetGeneric": "应用到全部:Off / Low / Medium / High(通用)",
43
- "card.capabilities.vendor": "提供方",
44
- "card.capabilities.developerRole": "网关不支持 developer 角色",
45
- "card.capabilities.developerRoleHint": "官方兼容开关(dsh ≥ v0.1.0-rc.8):写入路由级 compat.supportsDeveloperRole: false,系统提示词按 system 角色发送,修复 vLLM / SGLang 等网关的 Unexpected message role 400。取消勾选 = 删除该字段、恢复继承。",
46
- "card.capabilities.expandProvider": "展开提供方",
47
- "card.capabilities.collapseProvider": "收起提供方",
48
- "card.capabilities.openModelSettings": "打开模型设置",
49
- "card.capabilities.closeModelSettings": "收起模型设置",
50
- "card.capabilities.vision": "视觉模型",
51
- "card.capabilities.thinking": "思考模型",
52
- "card.capabilities.supportsEffort": "支持 think effort",
53
- "card.capabilities.efforts": "思考档位(勾选后填写线上值)",
54
- "card.capabilities.wirePlaceholder": "线上值,如 ultra",
55
- "card.capabilities.offPlaceholder": "留空 = 不发送",
56
- "card.capabilities.atLeastThinking": "至少需要一个思考档位(off 除外)",
57
- "card.capabilities.applyLevel": "应用此档位",
58
- "card.capabilities.restoreDefault": "恢复默认档位",
59
- "card.capabilities.unsaved": "未保存",
60
- "card.capabilities.saveChanges": "保存更改",
61
- "card.capabilities.saved": "已保存",
62
- "card.capabilities.thinkingFormat": "思考格式",
63
- "card.capabilities.thinkingFormat.inherit": "继承",
64
- "card.capabilities.contextWindow": "上下文窗口上限",
65
- "card.capabilities.contextCustomPlaceholder": "自定义整数,如 256000",
66
- "card.capabilities.contextClear": "清除",
67
- "card.capabilities.contextInteger": "上下文长度必须是整数(2000-1000000)",
68
- "card.capabilities.contextRange": "上下文长度必须在 2000 到 1000000 之间",
69
- "card.capabilities.contextHint": "选择预设或输入整数(2000–1000000),写入 llm-pi-ai 供上下文压力/压缩使用,无需重启即对下一请求生效。",
70
- "input.context.title": "上下文窗口",
71
- "input.context.globalHint": "全局生效:作用于所有使用该模型的会话(清除可恢复默认)",
72
- "input.context.unset": "未设",
73
- "input.context.custom": "自定义",
74
- "input.context.noModel": "暂无会话模型",
75
- "input.context.customPlaceholder": "自定义整数,如 256000",
76
- "input.context.apply": "应用",
77
- "input.context.clear": "清除",
78
- "input.context.integer": "上下文长度必须是整数(2000-1000000)",
79
- "input.context.range": "上下文长度必须在 2000 到 1000000 之间",
80
- "model.panel.choose": "选择模型",
81
- "model.panel.loading": "模型目录加载中…",
82
- "model.panel.empty": "没有可用模型",
83
- "model.panel.window": "窗口",
84
- "model.panel.noTarget": "该模型没有可写的配置项",
85
- "card.capabilities.failed": "保存失败:配置被拒绝或冲突,请检查值。"
86
- };
87
- /** English dictionary (keys mirror zh). */
88
- const en = {
89
- "card.title": "Thinking Levels",
90
- "family.title": "Qizi Plugin Settings",
91
- "card.description": "Pick Auto in the model selector: the plugin schedules low / high / max per tool round before submitting the API effort. Here you configure the default level, scheduler bounds, and per-model capabilities (level → gateway wire value mapping).",
92
- "card.level": "Default level",
93
- "card.level.off": "off — disable thinking (manual only, never auto-picked)",
94
- "card.level.on": "on — enable thinking (toggle-only models only; sends enable_thinking, never an effort)",
95
- "card.level.minimal": "minimal — least (very light tasks)",
96
- "card.level.low": "low — cheap rounds stay cheap",
97
- "card.level.medium": "medium — medium",
98
- "card.level.high": "high — the official default",
99
- "card.level.xhigh": "xhigh — extra high",
100
- "card.level.max": "max — heavy work",
101
- "card.level.auto": "auto — schedule from tool history (default)",
102
- "card.enabled": "Enabled",
103
- "card.allowDowngrade": "Allow downgrade (auto may drop to low)",
104
- "card.allowUpgrade": "Allow upgrade (auto may lift to max)",
105
- "card.unavailable": "Settings namespace unavailable: make sure dsh-thinking-levels is assembled into this profile.",
106
- "card.readonly": "Read-only",
107
- "card.capabilities": "Model capabilities (llm-pi-ai custom providers)",
108
- "card.capabilities.hint": "Reads and writes the llm-pi-ai config directly: tick a level and enter the exact value sent to the gateway (e.g. high → ultra); leaving off empty means “do not send”. Vision gates image input; the thinking toggle drives enable_thinking; thinkingFormat picks the wire serialization.",
109
- "card.capabilities.empty": "No custom provider has models configured in llm-pi-ai. Add a provider and models under Settings → Models first.",
110
- "card.capabilities.unavailable": "The llm-pi-ai settings namespace is unavailable.",
111
- "card.capabilities.none": "(no models)",
112
- "card.capabilities.search": "Search models by name or ID…",
113
- "card.capabilities.noMatches": "No matching models",
114
- "card.capabilities.quickSettings": "Quick settings",
115
- "card.capabilities.presetOfficial": "Apply to all: Off / High / Max (official DeepSeek style)",
116
- "card.capabilities.presetGeneric": "Apply to all: Off / Low / Medium / High (generic)",
117
- "card.capabilities.vendor": "Provider",
118
- "card.capabilities.developerRole": "Gateway rejects the developer role",
119
- "card.capabilities.developerRoleHint": "Official compat switch (dsh ≥ v0.1.0-rc.8): writes route-level compat.supportsDeveloperRole: false so the system prompt is sent as role system — fixes the Unexpected message role 400 on vLLM / SGLang gateways. Unchecking deletes the field and restores inheritance.",
120
- "card.capabilities.expandProvider": "Expand provider",
121
- "card.capabilities.collapseProvider": "Collapse provider",
122
- "card.capabilities.openModelSettings": "Open model settings",
123
- "card.capabilities.closeModelSettings": "Collapse model settings",
124
- "card.capabilities.vision": "Vision model",
125
- "card.capabilities.thinking": "Thinking model",
126
- "card.capabilities.supportsEffort": "Supports think effort",
127
- "card.capabilities.efforts": "Thinking effort levels (tick, then enter the wire value)",
128
- "card.capabilities.wirePlaceholder": "Wire value, e.g. ultra",
129
- "card.capabilities.offPlaceholder": "Empty = do not send",
130
- "card.capabilities.atLeastThinking": "Select at least one thinking level (other than off)",
131
- "card.capabilities.applyLevel": "Apply levels",
132
- "card.capabilities.restoreDefault": "Restore defaults",
133
- "card.capabilities.unsaved": "Unsaved",
134
- "card.capabilities.saveChanges": "Save changes",
135
- "card.capabilities.saved": "Saved",
136
- "card.capabilities.thinkingFormat": "Thinking format",
137
- "card.capabilities.thinkingFormat.inherit": "Inherit",
138
- "card.capabilities.contextWindow": "Context window limit",
139
- "card.capabilities.contextCustomPlaceholder": "Custom integer, e.g. 256000",
140
- "card.capabilities.contextClear": "Clear",
141
- "card.capabilities.contextInteger": "Context length must be an integer (2000-1000000)",
142
- "card.capabilities.contextRange": "Context length must be between 2000 and 1000000",
143
- "card.capabilities.contextHint": "Pick a preset or enter an integer (2000–1000000); written to llm-pi-ai for context pressure/compaction and applied to the next request without a restart.",
144
- "input.context.title": "Context window",
145
- "input.context.globalHint": "Applies globally to every session using this model (Clear restores the default)",
146
- "input.context.unset": "Unset",
147
- "input.context.custom": "Custom",
148
- "input.context.noModel": "No session model yet",
149
- "input.context.customPlaceholder": "Custom integer, e.g. 256000",
150
- "input.context.apply": "Apply",
151
- "input.context.clear": "Clear",
152
- "input.context.integer": "Context length must be an integer (2000-1000000)",
153
- "input.context.range": "Context length must be between 2000 and 1000000",
154
- "model.panel.choose": "Choose model",
155
- "model.panel.loading": "Loading the model directory…",
156
- "model.panel.empty": "No models available",
157
- "model.panel.window": "Window",
158
- "model.panel.noTarget": "No writable config entry for this model",
159
- "card.capabilities.failed": "Save failed: the value was rejected or conflicted. Check it."
160
- };
161
- /** Japanese dictionary (keys mirror zh). */
162
- const ja = {
163
- "card.title": "思考レベル",
164
- "family.title": "起子プラグイン設定",
165
- "card.description": "モデルセレクターで Auto(マスク)を選択すると、ツール呼び出し履歴から low / high / max を自動スケジュールして API に送信します。ここでは既定レベル、スケジューラーの境界、モデル能力(レベル → ゲートウェイ送信値のマッピング)を設定します。",
166
- "card.level": "既定レベル",
167
- "card.level.off": "off — 思考を無効化(手動のみ、自動選択はされません)",
168
- "card.level.on": "on — 思考を有効化(トグルのみのモデル向け。enable_thinking のみ送信、effort は送信しません)",
169
- "card.level.minimal": "minimal — 最小(非常に軽いタスク)",
170
- "card.level.low": "low — 低(軽いラウンドは軽いまま)",
171
- "card.level.medium": "medium — 中",
172
- "card.level.high": "high — 高(公式既定値)",
173
- "card.level.xhigh": "xhigh — 特高",
174
- "card.level.max": "max — 最大(重いタスク)",
175
- "card.level.auto": "auto — ツール履歴から自動スケジュール(既定)",
176
- "card.enabled": "有効",
177
- "card.allowDowngrade": "降格を許可(auto は low まで下げられる)",
178
- "card.allowUpgrade": "昇格を許可(auto は max まで上げられる)",
179
- "card.unavailable": "設定名前空間が利用できません:dsh-thinking-levels が profile に組み込まれているか確認してください。",
180
- "card.readonly": "読み取り専用",
181
- "card.capabilities": "モデル能力(llm-pi-ai カスタムプロバイダー)",
182
- "card.capabilities.hint": "llm-pi-ai 設定を直接読み書きします:レベルにチェックを入れ、ゲートウェイに送信する値を入力(例:high → ultra)。off を空欄にすると送信しません。視覚は画像入力を決定、思考トグルは enable_thinking を制御、thinkingFormat は wire シリアライズ形式を選択します。",
183
- "card.capabilities.empty": "llm-pi-ai にモデルが設定されたカスタムプロバイダーがありません。先に「設定 → モデル」でプロバイダーとモデルを追加してください。",
184
- "card.capabilities.unavailable": "llm-pi-ai の設定名前空間が利用できません。",
185
- "card.capabilities.none": "(モデルなし)",
186
- "card.capabilities.search": "モデル名または ID で検索…",
187
- "card.capabilities.noMatches": "一致するモデルがありません",
188
- "card.capabilities.quickSettings": "クイック設定",
189
- "card.capabilities.presetOfficial": "すべてに適用:Off / High / Max(公式 DeepSeek 形式)",
190
- "card.capabilities.presetGeneric": "すべてに適用:Off / Low / Medium / High(汎用)",
191
- "card.capabilities.vendor": "プロバイダー",
192
- "card.capabilities.developerRole": "ゲートウェイは developer ロール非対応",
193
- "card.capabilities.developerRoleHint": "公式互換スイッチ(dsh ≥ v0.1.0-rc.8):ルートレベルの compat.supportsDeveloperRole: false を書き込み、システムプロンプトを system ロールで送信します。vLLM / SGLang などの Unexpected message role 400 を修正。チェックを外すとフィールドを削除し継承に戻します。",
194
- "card.capabilities.expandProvider": "プロバイダーを展開",
195
- "card.capabilities.collapseProvider": "プロバイダーを折りたたむ",
196
- "card.capabilities.openModelSettings": "モデル設定を開く",
197
- "card.capabilities.closeModelSettings": "モデル設定を折りたたむ",
198
- "card.capabilities.vision": "視覚モデル",
199
- "card.capabilities.thinking": "思考モデル",
200
- "card.capabilities.supportsEffort": "think effort をサポート",
201
- "card.capabilities.efforts": "思考レベル(チェック後、送信値を入力)",
202
- "card.capabilities.wirePlaceholder": "送信値(例:ultra)",
203
- "card.capabilities.offPlaceholder": "空欄 = 送信しない",
204
- "card.capabilities.atLeastThinking": "思考レベルを 1 つ以上選択してください(off 以外)",
205
- "card.capabilities.applyLevel": "レベルを適用",
206
- "card.capabilities.restoreDefault": "既定値に戻す",
207
- "card.capabilities.unsaved": "未保存",
208
- "card.capabilities.saveChanges": "変更を保存",
209
- "card.capabilities.saved": "保存済み",
210
- "card.capabilities.thinkingFormat": "思考形式",
211
- "card.capabilities.thinkingFormat.inherit": "継承",
212
- "card.capabilities.contextWindow": "コンテキストウィンドウ上限",
213
- "card.capabilities.contextCustomPlaceholder": "カスタム整数(例:256000)",
214
- "card.capabilities.contextClear": "クリア",
215
- "card.capabilities.contextInteger": "コンテキスト長は整数で入力してください(2000-1000000)",
216
- "card.capabilities.contextRange": "コンテキスト長は 2000 から 1000000 の範囲で指定してください",
217
- "card.capabilities.contextHint": "プリセットを選ぶか整数を入力(2000–1000000)。llm-pi-ai に書き込まれ、コンテキスト圧力/圧縮に使用され、再起動なしで次のリクエストに反映されます。",
218
- "input.context.title": "コンテキストウィンドウ",
219
- "input.context.globalHint": "グローバルに有効:このモデルを使用するすべてのセッションに適用されます(クリアで既定値に戻ります)",
220
- "input.context.unset": "未設定",
221
- "input.context.custom": "カスタム",
222
- "input.context.noModel": "セッションモデルがまだありません",
223
- "input.context.customPlaceholder": "カスタム整数(例:256000)",
224
- "input.context.apply": "適用",
225
- "input.context.clear": "クリア",
226
- "input.context.integer": "コンテキスト長は整数で入力してください(2000-1000000)",
227
- "input.context.range": "コンテキスト長は 2000 から 1000000 の範囲で指定してください",
228
- "model.panel.choose": "モデルを選択",
229
- "model.panel.loading": "モデルディレクトリを読み込み中…",
230
- "model.panel.empty": "利用可能なモデルがありません",
231
- "model.panel.window": "ウィンドウ",
232
- "model.panel.noTarget": "このモデルには書き込み可能な設定項目がありません",
233
- "card.capabilities.failed": "保存に失敗しました:値が拒否されたか競合しています。確認してください。"
234
- };
235
- /** Korean dictionary (keys mirror zh). */
236
- const ko = {
237
- "card.title": "사고 수준",
238
- "family.title": "起子 플러그인 설정",
239
- "card.description": "모델 선택기에서 Auto(마스크)를 선택하면 도구 호출 기록을 기반으로 low / high / max 를 자동 스케줄링하여 API에 제출합니다. 여기서 기본 수준, 스케줄러 경계, 모델 기능(수준 → 게이트웨이 전송 값 매핑)을 구성합니다.",
240
- "card.level": "기본 수준",
241
- "card.level.off": "off — 사고 비활성화(수동 전용, 자동 선택 안 됨)",
242
- "card.level.on": "on — 사고 활성화(토글 전용 모델용. enable_thinking만 전송, effort는 전송하지 않음)",
243
- "card.level.minimal": "minimal — 최소(매우 가벼운 작업)",
244
- "card.level.low": "low — 낮음(가벼운 라운드는 가볍게 유지)",
245
- "card.level.medium": "medium — 중간",
246
- "card.level.high": "high — 높음(공식 기본값)",
247
- "card.level.xhigh": "xhigh — 특별히 높음",
248
- "card.level.max": "max — 최대(무거운 작업)",
249
- "card.level.auto": "auto — 도구 기록에서 자동 스케줄링(기본값)",
250
- "card.enabled": "활성화",
251
- "card.allowDowngrade": "다운그레이드 허용(auto가 low까지 내릴 수 있음)",
252
- "card.allowUpgrade": "업그레이드 허용(auto가 max까지 올릴 수 있음)",
253
- "card.unavailable": "설정 네임스페이스를 사용할 수 없습니다: dsh-thinking-levels가 이 profile에 조립되었는지 확인하세요.",
254
- "card.readonly": "읽기 전용",
255
- "card.capabilities": "모델 기능(llm-pi-ai 사용자 지정 제공자)",
256
- "card.capabilities.hint": "llm-pi-ai 설정을 직접 읽고 씁니다: 수준을 체크하고 게이트웨이에 보낼 값을 입력(예: high → ultra). off를 비워 두면 전송하지 않습니다. 시각은 이미지 입력을 결정하고, 사고 토글은 enable_thinking을 제어하며, thinkingFormat은 wire 직렬화 형식을 선택합니다.",
257
- "card.capabilities.empty": "llm-pi-ai에 모델이 구성된 사용자 지정 제공자가 없습니다. 먼저 「설정 → 모델」에서 제공자와 모델을 추가하세요.",
258
- "card.capabilities.unavailable": "llm-pi-ai 설정 네임스페이스를 사용할 수 없습니다.",
259
- "card.capabilities.none": "(모델 없음)",
260
- "card.capabilities.search": "모델 이름 또는 ID로 검색…",
261
- "card.capabilities.noMatches": "일치하는 모델이 없습니다",
262
- "card.capabilities.quickSettings": "빠른 설정",
263
- "card.capabilities.presetOfficial": "전체에 적용: Off / High / Max(공식 DeepSeek 방식)",
264
- "card.capabilities.presetGeneric": "전체에 적용: Off / Low / Medium / High(일반 방식)",
265
- "card.capabilities.vendor": "제공자",
266
- "card.capabilities.developerRole": "게이트웨이가 developer 역할 미지원",
267
- "card.capabilities.developerRoleHint": "공식 호환 스위치(dsh ≥ v0.1.0-rc.8): 라우트 수준 compat.supportsDeveloperRole: false 를 기록하여 시스템 프롬프트를 system 역할로 전송합니다. vLLM / SGLang 등의 Unexpected message role 400 을 수정. 체크 해제 시 필드를 삭제하고 상속을 복원합니다.",
268
- "card.capabilities.expandProvider": "제공자 펼치기",
269
- "card.capabilities.collapseProvider": "제공자 접기",
270
- "card.capabilities.openModelSettings": "모델 설정 열기",
271
- "card.capabilities.closeModelSettings": "모델 설정 접기",
272
- "card.capabilities.vision": "시각 모델",
273
- "card.capabilities.thinking": "사고 모델",
274
- "card.capabilities.supportsEffort": "think effort 지원",
275
- "card.capabilities.efforts": "사고 수준(체크 후 전송 값 입력)",
276
- "card.capabilities.wirePlaceholder": "전송 값(예: ultra)",
277
- "card.capabilities.offPlaceholder": "비워 둠 = 전송하지 않음",
278
- "card.capabilities.atLeastThinking": "사고 수준을 하나 이상 선택하세요(off 제외)",
279
- "card.capabilities.applyLevel": "수준 적용",
280
- "card.capabilities.restoreDefault": "기본값 복원",
281
- "card.capabilities.unsaved": "저장되지 않음",
282
- "card.capabilities.saveChanges": "변경 사항 저장",
283
- "card.capabilities.saved": "저장됨",
284
- "card.capabilities.thinkingFormat": "사고 형식",
285
- "card.capabilities.thinkingFormat.inherit": "상속",
286
- "card.capabilities.contextWindow": "컨텍스트 창 상한",
287
- "card.capabilities.contextCustomPlaceholder": "사용자 지정 정수(예: 256000)",
288
- "card.capabilities.contextClear": "지우기",
289
- "card.capabilities.contextInteger": "컨텍스트 길이는 정수여야 합니다 (2000-1000000)",
290
- "card.capabilities.contextRange": "컨텍스트 길이는 2000에서 1000000 사이여야 합니다",
291
- "card.capabilities.contextHint": "프리셋을 선택하거나 정수를 입력하세요(2000–1000000). llm-pi-ai에 기록되어 컨텍스트 압력/압축에 사용되며, 재시작 없이 다음 요청에 반영됩니다.",
292
- "input.context.title": "컨텍스트 창",
293
- "input.context.globalHint": "전역 적용: 이 모델을 사용하는 모든 세션에 적용됩니다(지우면 기본값 복원)",
294
- "input.context.unset": "미설정",
295
- "input.context.custom": "사용자 지정",
296
- "input.context.noModel": "세션 모델이 아직 없습니다",
297
- "input.context.customPlaceholder": "사용자 지정 정수(예: 256000)",
298
- "input.context.apply": "적용",
299
- "input.context.clear": "지우기",
300
- "input.context.integer": "컨텍스트 길이는 정수여야 합니다 (2000-1000000)",
301
- "input.context.range": "컨텍스트 길이는 2000에서 1000000 사이여야 합니다",
302
- "model.panel.choose": "모델 선택",
303
- "model.panel.loading": "모델 디렉터리를 불러오는 중…",
304
- "model.panel.empty": "사용 가능한 모델이 없습니다",
305
- "model.panel.window": "창",
306
- "model.panel.noTarget": "이 모델에는 쓰기 가능한 설정 항목이 없습니다",
307
- "card.capabilities.failed": "저장 실패: 값이 거부되었거나 충돌합니다. 확인하세요."
13
+ /** Combined dictionary map — all 9 languages, single-call registration. */
14
+ const dictionaries = {
15
+ zh: {
16
+ "card.title": "思考档位",
17
+ "family.title": "起子插件设置",
18
+ "card.description": "在模型选择器中可选 Auto(mask):按工具调用历史自动在 low / high / max 间调度后提交 API。此处配置默认档位、调度边界与模型能力(档位 → 网关线上值映射)。",
19
+ "card.level": "默认档位",
20
+ "card.level.off": "off — 关闭思考(仅手动,永不自动选择)",
21
+ "card.level.on": "on — 开启思考(仅 toggle 型模型;只发 enable_thinking,不发 effort)",
22
+ "card.level.minimal": "minimal — 最低(极轻任务)",
23
+ "card.level.low": "low — 低(简单任务,廉价轮保持廉价)",
24
+ "card.level.medium": "medium — 中",
25
+ "card.level.high": "high — 高(官方默认)",
26
+ "card.level.xhigh": "xhigh — 特高",
27
+ "card.level.max": "max — 最大(重任务)",
28
+ "card.level.auto": "auto — 按工具历史自动调度(默认)",
29
+ "card.enabled": "启用",
30
+ "card.allowDowngrade": "允许降档(auto 可降至 low)",
31
+ "card.allowUpgrade": "允许升档(auto 可升至 max)",
32
+ "card.unavailable": "设置命名空间不可用:请确认 dsh-thinking-levels 已装配进 profile。",
33
+ "card.readonly": "只读",
34
+ "card.capabilities": "模型能力(llm-pi-ai 自定义提供方)",
35
+ "card.capabilities.hint": "直接读写 llm-pi-ai 配置:勾选档位并填写发送给网关的线上值(例如 high → ultra);off 留空表示不发送。视觉决定图片输入;思考开关决定 enable_thinking 置位;thinkingFormat 决定 wire 序列化格式。",
36
+ "card.capabilities.empty": "llm-pi-ai 中没有已配置模型的自定义提供方。请先在「设置 → 模型」添加提供方与模型。",
37
+ "card.capabilities.unavailable": "llm-pi-ai 设置命名空间不可用。",
38
+ "card.capabilities.none": "(无模型)",
39
+ "card.capabilities.search": "搜索模型(名称或 ID)…",
40
+ "card.capabilities.noMatches": "没有匹配的模型",
41
+ "card.capabilities.quickSettings": "一键设置",
42
+ "card.capabilities.presetOfficial": "应用到全部:Off / High / Max(官方 DeepSeek 风格)",
43
+ "card.capabilities.presetGeneric": "应用到全部:Off / Low / Medium / High(通用)",
44
+ "card.capabilities.vendor": "提供方",
45
+ "card.capabilities.developerRole": "网关不支持 developer 角色",
46
+ "card.capabilities.developerRoleHint": "官方兼容开关(dsh ≥ v0.1.0-rc.8):写入路由级 compat.supportsDeveloperRole: false,系统提示词按 system 角色发送,修复 vLLM / SGLang 等网关的 Unexpected message role 400。取消勾选 = 删除该字段、恢复继承。",
47
+ "card.capabilities.expandProvider": "展开提供方",
48
+ "card.capabilities.collapseProvider": "收起提供方",
49
+ "card.capabilities.openModelSettings": "打开模型设置",
50
+ "card.capabilities.closeModelSettings": "收起模型设置",
51
+ "card.capabilities.vision": "视觉模型",
52
+ "card.capabilities.thinking": "思考模型",
53
+ "card.capabilities.supportsEffort": "支持 think effort",
54
+ "card.capabilities.efforts": "思考档位(勾选后填写线上值)",
55
+ "card.capabilities.wirePlaceholder": "线上值,如 ultra",
56
+ "card.capabilities.offPlaceholder": "留空 = 不发送",
57
+ "card.capabilities.atLeastThinking": "至少需要一个思考档位(off 除外)",
58
+ "card.capabilities.applyLevel": "应用此档位",
59
+ "card.capabilities.restoreDefault": "恢复默认档位",
60
+ "card.capabilities.unsaved": "未保存",
61
+ "card.capabilities.saveChanges": "保存更改",
62
+ "card.capabilities.saved": "已保存",
63
+ "card.capabilities.thinkingFormat": "思考格式",
64
+ "card.capabilities.thinkingFormat.inherit": "继承",
65
+ "card.capabilities.contextWindow": "上下文窗口上限",
66
+ "card.capabilities.contextCustomPlaceholder": "自定义整数,如 256000",
67
+ "card.capabilities.contextClear": "清除",
68
+ "card.capabilities.contextInteger": "上下文长度必须是整数(2000-1000000)",
69
+ "card.capabilities.contextRange": "上下文长度必须在 2000 到 1000000 之间",
70
+ "card.capabilities.contextHint": "选择预设或输入整数(2000–1000000),写入 llm-pi-ai 供上下文压力/压缩使用,无需重启即对下一请求生效。",
71
+ "input.context.title": "上下文窗口",
72
+ "input.context.globalHint": "全局生效:作用于所有使用该模型的会话(清除可恢复默认)",
73
+ "input.context.unset": "未设",
74
+ "input.context.custom": "自定义",
75
+ "input.context.noModel": "暂无会话模型",
76
+ "input.context.customPlaceholder": "自定义整数,如 256000",
77
+ "input.context.apply": "应用",
78
+ "input.context.clear": "清除",
79
+ "input.context.integer": "上下文长度必须是整数(2000-1000000)",
80
+ "input.context.range": "上下文长度必须在 2000 到 1000000 之间",
81
+ "model.panel.choose": "选择模型",
82
+ "model.panel.loading": "模型目录加载中…",
83
+ "model.panel.empty": "没有可用模型",
84
+ "model.panel.window": "窗口",
85
+ "model.panel.noTarget": "该模型没有可写的配置项",
86
+ "model.panel.unavailable": "当前会话的模型目录不可用",
87
+ "input.effort.title": "思考强度",
88
+ "input.effort.default": "提供方默认",
89
+ "card.capabilities.failed": "保存失败:配置被拒绝或冲突,请检查值。"
90
+ },
91
+ en: {
92
+ "card.title": "Thinking Levels",
93
+ "family.title": "Qizi Plugin Settings",
94
+ "card.description": "Pick Auto in the model selector: the plugin schedules low / high / max per tool round before submitting the API effort. Here you configure the default level, scheduler bounds, and per-model capabilities (level → gateway wire value mapping).",
95
+ "card.level": "Default level",
96
+ "card.level.off": "off — disable thinking (manual only, never auto-picked)",
97
+ "card.level.on": "on — enable thinking (toggle-only models only; sends enable_thinking, never an effort)",
98
+ "card.level.minimal": "minimal — least (very light tasks)",
99
+ "card.level.low": "low — cheap rounds stay cheap",
100
+ "card.level.medium": "medium — medium",
101
+ "card.level.high": "high — the official default",
102
+ "card.level.xhigh": "xhigh — extra high",
103
+ "card.level.max": "max — heavy work",
104
+ "card.level.auto": "auto — schedule from tool history (default)",
105
+ "card.enabled": "Enabled",
106
+ "card.allowDowngrade": "Allow downgrade (auto may drop to low)",
107
+ "card.allowUpgrade": "Allow upgrade (auto may lift to max)",
108
+ "card.unavailable": "Settings namespace unavailable: make sure dsh-thinking-levels is assembled into this profile.",
109
+ "card.readonly": "Read-only",
110
+ "card.capabilities": "Model capabilities (llm-pi-ai custom providers)",
111
+ "card.capabilities.hint": "Reads and writes the llm-pi-ai config directly: tick a level and enter the exact value sent to the gateway (e.g. high → ultra); leaving off empty means “do not send”. Vision gates image input; the thinking toggle drives enable_thinking; thinkingFormat picks the wire serialization.",
112
+ "card.capabilities.empty": "No custom provider has models configured in llm-pi-ai. Add a provider and models under Settings → Models first.",
113
+ "card.capabilities.unavailable": "The llm-pi-ai settings namespace is unavailable.",
114
+ "card.capabilities.none": "(no models)",
115
+ "card.capabilities.search": "Search models by name or ID…",
116
+ "card.capabilities.noMatches": "No matching models",
117
+ "card.capabilities.quickSettings": "Quick settings",
118
+ "card.capabilities.presetOfficial": "Apply to all: Off / High / Max (official DeepSeek style)",
119
+ "card.capabilities.presetGeneric": "Apply to all: Off / Low / Medium / High (generic)",
120
+ "card.capabilities.vendor": "Provider",
121
+ "card.capabilities.developerRole": "Gateway rejects the developer role",
122
+ "card.capabilities.developerRoleHint": "Official compat switch (dsh ≥ v0.1.0-rc.8): writes route-level compat.supportsDeveloperRole: false so the system prompt is sent as role system — fixes the Unexpected message role 400 on vLLM / SGLang gateways. Unchecking deletes the field and restores inheritance.",
123
+ "card.capabilities.expandProvider": "Expand provider",
124
+ "card.capabilities.collapseProvider": "Collapse provider",
125
+ "card.capabilities.openModelSettings": "Open model settings",
126
+ "card.capabilities.closeModelSettings": "Collapse model settings",
127
+ "card.capabilities.vision": "Vision model",
128
+ "card.capabilities.thinking": "Thinking model",
129
+ "card.capabilities.supportsEffort": "Supports think effort",
130
+ "card.capabilities.efforts": "Thinking effort levels (tick, then enter the wire value)",
131
+ "card.capabilities.wirePlaceholder": "Wire value, e.g. ultra",
132
+ "card.capabilities.offPlaceholder": "Empty = do not send",
133
+ "card.capabilities.atLeastThinking": "Select at least one thinking level (other than off)",
134
+ "card.capabilities.applyLevel": "Apply levels",
135
+ "card.capabilities.restoreDefault": "Restore defaults",
136
+ "card.capabilities.unsaved": "Unsaved",
137
+ "card.capabilities.saveChanges": "Save changes",
138
+ "card.capabilities.saved": "Saved",
139
+ "card.capabilities.thinkingFormat": "Thinking format",
140
+ "card.capabilities.thinkingFormat.inherit": "Inherit",
141
+ "card.capabilities.contextWindow": "Context window limit",
142
+ "card.capabilities.contextCustomPlaceholder": "Custom integer, e.g. 256000",
143
+ "card.capabilities.contextClear": "Clear",
144
+ "card.capabilities.contextInteger": "Context length must be an integer (2000-1000000)",
145
+ "card.capabilities.contextRange": "Context length must be between 2000 and 1000000",
146
+ "card.capabilities.contextHint": "Pick a preset or enter an integer (2000–1000000); written to llm-pi-ai for context pressure/compaction and applied to the next request without a restart.",
147
+ "input.context.title": "Context window",
148
+ "input.context.globalHint": "Applies globally to every session using this model (Clear restores the default)",
149
+ "input.context.unset": "Unset",
150
+ "input.context.custom": "Custom",
151
+ "input.context.noModel": "No session model yet",
152
+ "input.context.customPlaceholder": "Custom integer, e.g. 256000",
153
+ "input.context.apply": "Apply",
154
+ "input.context.clear": "Clear",
155
+ "input.context.integer": "Context length must be an integer (2000-1000000)",
156
+ "input.context.range": "Context length must be between 2000 and 1000000",
157
+ "model.panel.choose": "Choose model",
158
+ "model.panel.loading": "Loading the model directory…",
159
+ "model.panel.empty": "No models available",
160
+ "model.panel.window": "Window",
161
+ "model.panel.noTarget": "No writable config entry for this model",
162
+ "model.panel.unavailable": "The model directory is unavailable for this session",
163
+ "input.effort.title": "Reasoning effort",
164
+ "input.effort.default": "Provider default",
165
+ "card.capabilities.failed": "Save failed: the value was rejected or conflicted. Check it."
166
+ },
167
+ ja: {
168
+ "card.title": "思考レベル",
169
+ "family.title": "起子プラグイン設定",
170
+ "card.description": "モデルセレクターで Auto(マスク)を選択すると、ツール呼び出し履歴から low / high / max を自動スケジュールして API に送信します。ここでは既定レベル、スケジューラーの境界、モデル能力(レベル → ゲートウェイ送信値のマッピング)を設定します。",
171
+ "card.level": "既定レベル",
172
+ "card.level.off": "off — 思考を無効化(手動のみ、自動選択はされません)",
173
+ "card.level.on": "on — 思考を有効化(トグルのみのモデル向け。enable_thinking のみ送信、effort は送信しません)",
174
+ "card.level.minimal": "minimal — 最小(非常に軽いタスク)",
175
+ "card.level.low": "low — 低(軽いラウンドは軽いまま)",
176
+ "card.level.medium": "medium — 中",
177
+ "card.level.high": "high — 高(公式既定値)",
178
+ "card.level.xhigh": "xhigh — 特高",
179
+ "card.level.max": "max — 最大(重いタスク)",
180
+ "card.level.auto": "auto — ツール履歴から自動スケジュール(既定)",
181
+ "card.enabled": "有効",
182
+ "card.allowDowngrade": "降格を許可(auto は low まで下げられる)",
183
+ "card.allowUpgrade": "昇格を許可(auto は max まで上げられる)",
184
+ "card.unavailable": "設定名前空間が利用できません:dsh-thinking-levels が profile に組み込まれているか確認してください。",
185
+ "card.readonly": "読み取り専用",
186
+ "card.capabilities": "モデル能力(llm-pi-ai カスタムプロバイダー)",
187
+ "card.capabilities.hint": "llm-pi-ai 設定を直接読み書きします:レベルにチェックを入れ、ゲートウェイに送信する値を入力(例:high → ultra)。off を空欄にすると送信しません。視覚は画像入力を決定、思考トグルは enable_thinking を制御、thinkingFormat は wire シリアライズ形式を選択します。",
188
+ "card.capabilities.empty": "llm-pi-ai にモデルが設定されたカスタムプロバイダーがありません。先に「設定 → モデル」でプロバイダーとモデルを追加してください。",
189
+ "card.capabilities.unavailable": "llm-pi-ai の設定名前空間が利用できません。",
190
+ "card.capabilities.none": "(モデルなし)",
191
+ "card.capabilities.search": "モデル名または ID で検索…",
192
+ "card.capabilities.noMatches": "一致するモデルがありません",
193
+ "card.capabilities.quickSettings": "クイック設定",
194
+ "card.capabilities.presetOfficial": "すべてに適用:Off / High / Max(公式 DeepSeek 形式)",
195
+ "card.capabilities.presetGeneric": "すべてに適用:Off / Low / Medium / High(汎用)",
196
+ "card.capabilities.vendor": "プロバイダー",
197
+ "card.capabilities.developerRole": "ゲートウェイは developer ロール非対応",
198
+ "card.capabilities.developerRoleHint": "公式互換スイッチ(dsh ≥ v0.1.0-rc.8):ルートレベルの compat.supportsDeveloperRole: false を書き込み、システムプロンプトを system ロールで送信します。vLLM / SGLang などの Unexpected message role 400 を修正。チェックを外すとフィールドを削除し継承に戻します。",
199
+ "card.capabilities.expandProvider": "プロバイダーを展開",
200
+ "card.capabilities.collapseProvider": "プロバイダーを折りたたむ",
201
+ "card.capabilities.openModelSettings": "モデル設定を開く",
202
+ "card.capabilities.closeModelSettings": "モデル設定を折りたたむ",
203
+ "card.capabilities.vision": "視覚モデル",
204
+ "card.capabilities.thinking": "思考モデル",
205
+ "card.capabilities.supportsEffort": "think effort をサポート",
206
+ "card.capabilities.efforts": "思考レベル(チェック後、送信値を入力)",
207
+ "card.capabilities.wirePlaceholder": "送信値(例:ultra)",
208
+ "card.capabilities.offPlaceholder": "空欄 = 送信しない",
209
+ "card.capabilities.atLeastThinking": "思考レベルを 1 つ以上選択してください(off 以外)",
210
+ "card.capabilities.applyLevel": "レベルを適用",
211
+ "card.capabilities.restoreDefault": "既定値に戻す",
212
+ "card.capabilities.unsaved": "未保存",
213
+ "card.capabilities.saveChanges": "変更を保存",
214
+ "card.capabilities.saved": "保存済み",
215
+ "card.capabilities.thinkingFormat": "思考形式",
216
+ "card.capabilities.thinkingFormat.inherit": "継承",
217
+ "card.capabilities.contextWindow": "コンテキストウィンドウ上限",
218
+ "card.capabilities.contextCustomPlaceholder": "カスタム整数(例:256000)",
219
+ "card.capabilities.contextClear": "クリア",
220
+ "card.capabilities.contextInteger": "コンテキスト長は整数で入力してください(2000-1000000)",
221
+ "card.capabilities.contextRange": "コンテキスト長は 2000 から 1000000 の範囲で指定してください",
222
+ "card.capabilities.contextHint": "プリセットを選ぶか整数を入力(2000–1000000)。llm-pi-ai に書き込まれ、コンテキスト圧力/圧縮に使用され、再起動なしで次のリクエストに反映されます。",
223
+ "input.context.title": "コンテキストウィンドウ",
224
+ "input.context.globalHint": "グローバルに有効:このモデルを使用するすべてのセッションに適用されます(クリアで既定値に戻ります)",
225
+ "input.context.unset": "未設定",
226
+ "input.context.custom": "カスタム",
227
+ "input.context.noModel": "セッションモデルがまだありません",
228
+ "input.context.customPlaceholder": "カスタム整数(例:256000)",
229
+ "input.context.apply": "適用",
230
+ "input.context.clear": "クリア",
231
+ "input.context.integer": "コンテキスト長は整数で入力してください(2000-1000000)",
232
+ "input.context.range": "コンテキスト長は 2000 から 1000000 の範囲で指定してください",
233
+ "model.panel.choose": "モデルを選択",
234
+ "model.panel.loading": "モデルディレクトリを読み込み中…",
235
+ "model.panel.empty": "利用可能なモデルがありません",
236
+ "model.panel.window": "ウィンドウ",
237
+ "model.panel.noTarget": "このモデルには書き込み可能な設定項目がありません",
238
+ "model.panel.unavailable": "このセッションのモデルディレクトリは利用できません",
239
+ "input.effort.title": "思考レベル",
240
+ "input.effort.default": "プロバイダーの既定",
241
+ "card.capabilities.failed": "保存に失敗しました:値が拒否されたか競合しています。確認してください。"
242
+ },
243
+ ko: {
244
+ "card.title": "사고 수준",
245
+ "family.title": "起子 플러그인 설정",
246
+ "card.description": "모델 선택기에서 Auto(마스크)를 선택하면 도구 호출 기록을 기반으로 low / high / max 를 자동 스케줄링하여 API에 제출합니다. 여기서 기본 수준, 스케줄러 경계, 모델 기능(수준 → 게이트웨이 전송 값 매핑)을 구성합니다.",
247
+ "card.level": "기본 수준",
248
+ "card.level.off": "off — 사고 비활성화(수동 전용, 자동 선택 안 됨)",
249
+ "card.level.on": "on — 사고 활성화(토글 전용 모델용. enable_thinking만 전송, effort는 전송하지 않음)",
250
+ "card.level.minimal": "minimal — 최소(매우 가벼운 작업)",
251
+ "card.level.low": "low — 낮음(가벼운 라운드는 가볍게 유지)",
252
+ "card.level.medium": "medium — 중간",
253
+ "card.level.high": "high — 높음(공식 기본값)",
254
+ "card.level.xhigh": "xhigh — 특별히 높음",
255
+ "card.level.max": "max — 최대(무거운 작업)",
256
+ "card.level.auto": "auto — 도구 기록에서 자동 스케줄링(기본값)",
257
+ "card.enabled": "활성화",
258
+ "card.allowDowngrade": "다운그레이드 허용(auto가 low까지 내릴 수 있음)",
259
+ "card.allowUpgrade": "업그레이드 허용(auto가 max까지 올릴 수 있음)",
260
+ "card.unavailable": "설정 네임스페이스를 사용할 수 없습니다: dsh-thinking-levels가 이 profile에 조립되었는지 확인하세요.",
261
+ "card.readonly": "읽기 전용",
262
+ "card.capabilities": "모델 기능(llm-pi-ai 사용자 지정 제공자)",
263
+ "card.capabilities.hint": "llm-pi-ai 설정을 직접 읽고 씁니다: 수준을 체크하고 게이트웨이에 보낼 값을 입력(예: high → ultra). off를 비워 두면 전송하지 않습니다. 시각은 이미지 입력을 결정하고, 사고 토글은 enable_thinking을 제어하며, thinkingFormat은 wire 직렬화 형식을 선택합니다.",
264
+ "card.capabilities.empty": "llm-pi-ai에 모델이 구성된 사용자 지정 제공자가 없습니다. 먼저 「설정 → 모델」에서 제공자와 모델을 추가하세요.",
265
+ "card.capabilities.unavailable": "llm-pi-ai 설정 네임스페이스를 사용할 수 없습니다.",
266
+ "card.capabilities.none": "(모델 없음)",
267
+ "card.capabilities.search": "모델 이름 또는 ID로 검색…",
268
+ "card.capabilities.noMatches": "일치하는 모델이 없습니다",
269
+ "card.capabilities.quickSettings": "빠른 설정",
270
+ "card.capabilities.presetOfficial": "전체에 적용: Off / High / Max(공식 DeepSeek 방식)",
271
+ "card.capabilities.presetGeneric": "전체에 적용: Off / Low / Medium / High(일반 방식)",
272
+ "card.capabilities.vendor": "제공자",
273
+ "card.capabilities.developerRole": "게이트웨이가 developer 역할 미지원",
274
+ "card.capabilities.developerRoleHint": "공식 호환 스위치(dsh ≥ v0.1.0-rc.8): 라우트 수준 compat.supportsDeveloperRole: false 를 기록하여 시스템 프롬프트를 system 역할로 전송합니다. vLLM / SGLang 등의 Unexpected message role 400 을 수정. 체크 해제 시 필드를 삭제하고 상속을 복원합니다.",
275
+ "card.capabilities.expandProvider": "제공자 펼치기",
276
+ "card.capabilities.collapseProvider": "제공자 접기",
277
+ "card.capabilities.openModelSettings": "모델 설정 열기",
278
+ "card.capabilities.closeModelSettings": "모델 설정 접기",
279
+ "card.capabilities.vision": "시각 모델",
280
+ "card.capabilities.thinking": "사고 모델",
281
+ "card.capabilities.supportsEffort": "think effort 지원",
282
+ "card.capabilities.efforts": "사고 수준(체크 후 전송 값 입력)",
283
+ "card.capabilities.wirePlaceholder": "전송 값(예: ultra)",
284
+ "card.capabilities.offPlaceholder": "비워 둠 = 전송하지 않음",
285
+ "card.capabilities.atLeastThinking": "사고 수준을 하나 이상 선택하세요(off 제외)",
286
+ "card.capabilities.applyLevel": "수준 적용",
287
+ "card.capabilities.restoreDefault": "기본값 복원",
288
+ "card.capabilities.unsaved": "저장되지 않음",
289
+ "card.capabilities.saveChanges": "변경 사항 저장",
290
+ "card.capabilities.saved": "저장됨",
291
+ "card.capabilities.thinkingFormat": "사고 형식",
292
+ "card.capabilities.thinkingFormat.inherit": "상속",
293
+ "card.capabilities.contextWindow": "컨텍스트 창 상한",
294
+ "card.capabilities.contextCustomPlaceholder": "사용자 지정 정수(예: 256000)",
295
+ "card.capabilities.contextClear": "지우기",
296
+ "card.capabilities.contextInteger": "컨텍스트 길이는 정수여야 합니다 (2000-1000000)",
297
+ "card.capabilities.contextRange": "컨텍스트 길이는 2000에서 1000000 사이여야 합니다",
298
+ "card.capabilities.contextHint": "프리셋을 선택하거나 정수를 입력하세요(2000–1000000). llm-pi-ai에 기록되어 컨텍스트 압력/압축에 사용되며, 재시작 없이 다음 요청에 반영됩니다.",
299
+ "input.context.title": "컨텍스트 창",
300
+ "input.context.globalHint": "전역 적용: 이 모델을 사용하는 모든 세션에 적용됩니다(지우면 기본값 복원)",
301
+ "input.context.unset": "미설정",
302
+ "input.context.custom": "사용자 지정",
303
+ "input.context.noModel": "세션 모델이 아직 없습니다",
304
+ "input.context.customPlaceholder": "사용자 지정 정수(예: 256000)",
305
+ "input.context.apply": "적용",
306
+ "input.context.clear": "지우기",
307
+ "input.context.integer": "컨텍스트 길이는 정수여야 합니다 (2000-1000000)",
308
+ "input.context.range": "컨텍스트 길이는 2000에서 1000000 사이여야 합니다",
309
+ "model.panel.choose": "모델 선택",
310
+ "model.panel.loading": "모델 디렉터리를 불러오는 중…",
311
+ "model.panel.empty": "사용 가능한 모델이 없습니다",
312
+ "model.panel.window": "창",
313
+ "model.panel.noTarget": "이 모델에는 쓰기 가능한 설정 항목이 없습니다",
314
+ "model.panel.unavailable": "이 세션의 모델 디렉터리를 사용할 수 없습니다",
315
+ "input.effort.title": "추론 강도",
316
+ "input.effort.default": "공급자 기본값",
317
+ "card.capabilities.failed": "저장 실패: 값이 거부되었거나 충돌합니다. 확인하세요."
318
+ },
319
+ fr: {
320
+ "card.title": "Niveaux de réflexion",
321
+ "family.title": "Paramètres des plugins Qizi",
322
+ "card.description": "Choisissez Auto dans le sélecteur de modèle : le plugin planifie low / high / max selon l'historique des appels d'outils avant de soumettre l'effort à l'API. Configurez ici le niveau par défaut, les limites du planificateur et les capacités par modèle (niveau → valeur envoyée à la passerelle).",
323
+ "card.level": "Niveau par défaut",
324
+ "card.level.off": "off — désactiver la réflexion (manuel uniquement, jamais auto-sélectionné)",
325
+ "card.level.on": "on — activer la réflexion (modèles à bascule uniquement ; envoie enable_thinking, jamais d'effort)",
326
+ "card.level.minimal": "minimal — minimum (tâches très légères)",
327
+ "card.level.low": "low — bas (tours économiques restent économiques)",
328
+ "card.level.medium": "medium — moyen",
329
+ "card.level.high": "high — élevé (valeur officielle par défaut)",
330
+ "card.level.xhigh": "xhigh — très élevé",
331
+ "card.level.max": "max — maximum (tâches lourdes)",
332
+ "card.level.auto": "auto — planification depuis l'historique des outils (par défaut)",
333
+ "card.enabled": "Activé",
334
+ "card.allowDowngrade": "Autoriser la rétrogradation (auto peut descendre à low)",
335
+ "card.allowUpgrade": "Autoriser la montée (auto peut monter à max)",
336
+ "card.unavailable": "Espace de noms des paramètres indisponible : assurez-vous que dsh-thinking-levels est assemblé dans ce profil.",
337
+ "card.readonly": "Lecture seule",
338
+ "card.capabilities": "Capacités du modèle (fournisseurs personnalisés llm-pi-ai)",
339
+ "card.capabilities.hint": "Lit et écrit directement la configuration llm-pi-ai : cochez un niveau et saisissez la valeur exacte envoyée à la passerelle (ex. high → ultra) ; laisser off vide signifie « ne pas envoyer ». Vision contrôle l'entrée d'image ; le bouton de réflexion pilote enable_thinking ; thinkingFormat choisit la sérialisation wire.",
340
+ "card.capabilities.empty": "Aucun fournisseur personnalisé n'a de modèles configurés dans llm-pi-ai. Ajoutez d'abord un fournisseur et des modèles dans Paramètres → Modèles.",
341
+ "card.capabilities.unavailable": "L'espace de noms des paramètres llm-pi-ai est indisponible.",
342
+ "card.capabilities.none": "(aucun modèle)",
343
+ "card.capabilities.search": "Rechercher des modèles par nom ou ID…",
344
+ "card.capabilities.noMatches": "Aucun modèle correspondant",
345
+ "card.capabilities.quickSettings": "Paramètres rapides",
346
+ "card.capabilities.presetOfficial": "Appliquer à tous : Off / High / Max (style officiel DeepSeek)",
347
+ "card.capabilities.presetGeneric": "Appliquer à tous : Off / Low / Medium / High (générique)",
348
+ "card.capabilities.vendor": "Fournisseur",
349
+ "card.capabilities.developerRole": "La passerelle rejette le rôle developer",
350
+ "card.capabilities.developerRoleHint": "Commutateur de compatibilité officiel (dsh ≥ v0.1.0-rc.8) : écrit compat.supportsDeveloperRole: false au niveau de la route pour que le prompt système soit envoyé avec le rôle system — corrige l'erreur Unexpected message role 400 sur les passerelles vLLM / SGLang. Décocher supprime le champ et restaure l'héritage.",
351
+ "card.capabilities.expandProvider": "Déplier le fournisseur",
352
+ "card.capabilities.collapseProvider": "Replier le fournisseur",
353
+ "card.capabilities.openModelSettings": "Ouvrir les paramètres du modèle",
354
+ "card.capabilities.closeModelSettings": "Replier les paramètres du modèle",
355
+ "card.capabilities.vision": "Modèle vision",
356
+ "card.capabilities.thinking": "Modèle de réflexion",
357
+ "card.capabilities.supportsEffort": "Prend en charge think effort",
358
+ "card.capabilities.efforts": "Niveaux de réflexion (cochez, puis saisissez la valeur wire)",
359
+ "card.capabilities.wirePlaceholder": "Valeur wire, ex. ultra",
360
+ "card.capabilities.offPlaceholder": "Vide = ne pas envoyer",
361
+ "card.capabilities.atLeastThinking": "Sélectionnez au moins un niveau de réflexion (autre que off)",
362
+ "card.capabilities.applyLevel": "Appliquer les niveaux",
363
+ "card.capabilities.restoreDefault": "Restaurer les valeurs par défaut",
364
+ "card.capabilities.unsaved": "Non enregistré",
365
+ "card.capabilities.saveChanges": "Enregistrer les modifications",
366
+ "card.capabilities.saved": "Enregistré",
367
+ "card.capabilities.thinkingFormat": "Format de réflexion",
368
+ "card.capabilities.thinkingFormat.inherit": "Hériter",
369
+ "card.capabilities.contextWindow": "Limite de fenêtre de contexte",
370
+ "card.capabilities.contextCustomPlaceholder": "Entier personnalisé, ex. 256000",
371
+ "card.capabilities.contextClear": "Effacer",
372
+ "card.capabilities.contextInteger": "La longueur du contexte doit être un entier (2000-1000000)",
373
+ "card.capabilities.contextRange": "La longueur du contexte doit être comprise entre 2000 et 1000000",
374
+ "card.capabilities.contextHint": "Choisissez un préréglage ou saisissez un entier (2000–1000000) ; écrit dans llm-pi-ai pour la pression/compression du contexte et appliqué à la requête suivante sans redémarrage.",
375
+ "input.context.title": "Fenêtre de contexte",
376
+ "input.context.globalHint": "S'applique globalement à toutes les sessions utilisant ce modèle (Effacer restaure la valeur par défaut)",
377
+ "input.context.unset": "Non défini",
378
+ "input.context.custom": "Personnalisé",
379
+ "input.context.noModel": "Aucun modèle de session",
380
+ "input.context.customPlaceholder": "Entier personnalisé, ex. 256000",
381
+ "input.context.apply": "Appliquer",
382
+ "input.context.clear": "Effacer",
383
+ "input.context.integer": "La longueur du contexte doit être un entier (2000-1000000)",
384
+ "input.context.range": "La longueur du contexte doit être comprise entre 2000 et 1000000",
385
+ "model.panel.choose": "Choisir un modèle",
386
+ "model.panel.loading": "Chargement du répertoire de modèles…",
387
+ "model.panel.empty": "Aucun modèle disponible",
388
+ "model.panel.window": "Fenêtre",
389
+ "model.panel.noTarget": "Aucune entrée de configuration inscriptible pour ce modèle",
390
+ "model.panel.unavailable": "Le répertoire de modèles est indisponible pour cette session",
391
+ "input.effort.title": "Effort de raisonnement",
392
+ "input.effort.default": "Valeur par défaut du fournisseur",
393
+ "card.capabilities.failed": "Échec de l'enregistrement : la valeur a été rejetée ou est en conflit. Vérifiez-la."
394
+ },
395
+ de: {
396
+ "card.title": "Denkstufen",
397
+ "family.title": "Qizi-Plugin-Einstellungen",
398
+ "card.description": "Wählen Sie Auto im Modellselektor: Das Plugin plant low / high / max anhand des Tool-Aufrufverlaufs, bevor der API-Aufwand übermittelt wird. Hier konfigurieren Sie die Standardstufe, Planer-Grenzen und Modellfähigkeiten (Stufe → Gateway-Drahtwert-Zuordnung).",
399
+ "card.level": "Standardstufe",
400
+ "card.level.off": "off — Denken deaktivieren (nur manuell, nie automatisch gewählt)",
401
+ "card.level.on": "on — Denken aktivieren (nur Umschaltmodelle; sendet enable_thinking, nie einen Aufwand)",
402
+ "card.level.minimal": "minimal — geringst (sehr leichte Aufgaben)",
403
+ "card.level.low": "low — niedrig (günstige Runden bleiben günstig)",
404
+ "card.level.medium": "medium — mittel",
405
+ "card.level.high": "high — hoch (offizieller Standard)",
406
+ "card.level.xhigh": "xhigh — extra hoch",
407
+ "card.level.max": "max — maximal (schwere Aufgaben)",
408
+ "card.level.auto": "auto — Planung aus Tool-Verlauf (Standard)",
409
+ "card.enabled": "Aktiviert",
410
+ "card.allowDowngrade": "Herabstufung erlauben (auto kann auf low fallen)",
411
+ "card.allowUpgrade": "Hochstufung erlauben (auto kann auf max steigen)",
412
+ "card.unavailable": "Einstellungs-Namensraum nicht verfügbar: Stellen Sie sicher, dass dsh-thinking-levels in diesem Profil eingebunden ist.",
413
+ "card.readonly": "Schreibgeschützt",
414
+ "card.capabilities": "Modellfähigkeiten (llm-pi-ai benutzerdefinierte Anbieter)",
415
+ "card.capabilities.hint": "Liest und schreibt die llm-pi-ai-Konfiguration direkt: Aktivieren Sie eine Stufe und geben Sie den genauen Wert ein, der an das Gateway gesendet wird (z. B. high → ultra); off leer lassen bedeutet „nicht senden\". Vision steuert die Bild-Eingabe; der Denk-Schalter treibt enable_thinking; thinkingFormat wählt die Wire-Serialisierung.",
416
+ "card.capabilities.empty": "Kein benutzerdefinierter Anbieter hat Modelle in llm-pi-ai konfiguriert. Fügen Sie zuerst einen Anbieter und Modelle unter Einstellungen → Modelle hinzu.",
417
+ "card.capabilities.unavailable": "Der llm-pi-ai Einstellungs-Namensraum ist nicht verfügbar.",
418
+ "card.capabilities.none": "(keine Modelle)",
419
+ "card.capabilities.search": "Modelle nach Name oder ID suchen…",
420
+ "card.capabilities.noMatches": "Keine passenden Modelle",
421
+ "card.capabilities.quickSettings": "Schnelleinstellungen",
422
+ "card.capabilities.presetOfficial": "Auf alle anwenden: Off / High / Max (offizieller DeepSeek-Stil)",
423
+ "card.capabilities.presetGeneric": "Auf alle anwenden: Off / Low / Medium / High (generisch)",
424
+ "card.capabilities.vendor": "Anbieter",
425
+ "card.capabilities.developerRole": "Gateway lehnt die Entwickler-Rolle ab",
426
+ "card.capabilities.developerRoleHint": "Offizieller Kompatibilitätsschalter (dsh ≥ v0.1.0-rc.8): Schreibt compat.supportsDeveloperRole: false auf Routenebene, damit der System-Prompt als Rolle system gesendet wird — behebt den Unexpected message role 400 auf vLLM / SGLang Gateways. Deaktivieren löscht das Feld und stellt die Vererbung wieder her.",
427
+ "card.capabilities.expandProvider": "Anbieter aufklappen",
428
+ "card.capabilities.collapseProvider": "Anbieter einklappen",
429
+ "card.capabilities.openModelSettings": "Modelleinstellungen öffnen",
430
+ "card.capabilities.closeModelSettings": "Modelleinstellungen einklappen",
431
+ "card.capabilities.vision": "Vision-Modell",
432
+ "card.capabilities.thinking": "Denkmodell",
433
+ "card.capabilities.supportsEffort": "Unterstützt think effort",
434
+ "card.capabilities.efforts": "Denkstufen (aktivieren, dann Drahtwert eingeben)",
435
+ "card.capabilities.wirePlaceholder": "Drahtwert, z. B. ultra",
436
+ "card.capabilities.offPlaceholder": "Leer = nicht senden",
437
+ "card.capabilities.atLeastThinking": "Wählen Sie mindestens eine Denkstufe (außer off)",
438
+ "card.capabilities.applyLevel": "Stufen anwenden",
439
+ "card.capabilities.restoreDefault": "Standardwerte wiederherstellen",
440
+ "card.capabilities.unsaved": "Ungespeichert",
441
+ "card.capabilities.saveChanges": "Änderungen speichern",
442
+ "card.capabilities.saved": "Gespeichert",
443
+ "card.capabilities.thinkingFormat": "Denkformat",
444
+ "card.capabilities.thinkingFormat.inherit": "Erben",
445
+ "card.capabilities.contextWindow": "Kontextfenster-Limit",
446
+ "card.capabilities.contextCustomPlaceholder": "Benutzerdefinierte Ganzzahl, z. B. 256000",
447
+ "card.capabilities.contextClear": "Löschen",
448
+ "card.capabilities.contextInteger": "Kontextlänge muss eine Ganzzahl sein (2000-1000000)",
449
+ "card.capabilities.contextRange": "Kontextlänge muss zwischen 2000 und 1000000 liegen",
450
+ "card.capabilities.contextHint": "Wählen Sie eine Voreinstellung oder geben Sie eine Ganzzahl ein (2000–1000000); wird in llm-pi-ai geschrieben für Kontextdruck/Komprimierung und gilt ab der nächsten Anfrage ohne Neustart.",
451
+ "input.context.title": "Kontextfenster",
452
+ "input.context.globalHint": "Gilt global für alle Sitzungen mit diesem Modell (Löschen stellt den Standard wieder her)",
453
+ "input.context.unset": "Nicht festgelegt",
454
+ "input.context.custom": "Benutzerdefiniert",
455
+ "input.context.noModel": "Noch kein Sitzungsmodell",
456
+ "input.context.customPlaceholder": "Benutzerdefinierte Ganzzahl, z. B. 256000",
457
+ "input.context.apply": "Anwenden",
458
+ "input.context.clear": "Löschen",
459
+ "input.context.integer": "Kontextlänge muss eine Ganzzahl sein (2000-1000000)",
460
+ "input.context.range": "Kontextlänge muss zwischen 2000 und 1000000 liegen",
461
+ "model.panel.choose": "Modell wählen",
462
+ "model.panel.loading": "Modellverzeichnis wird geladen…",
463
+ "model.panel.empty": "Keine Modelle verfügbar",
464
+ "model.panel.window": "Fenster",
465
+ "model.panel.noTarget": "Kein beschreibbarer Konfigurationseintrag für dieses Modell",
466
+ "model.panel.unavailable": "Das Modellverzeichnis ist für diese Sitzung nicht verfügbar",
467
+ "input.effort.title": "Schlussfolgerungsaufwand",
468
+ "input.effort.default": "Anbieterstandard",
469
+ "card.capabilities.failed": "Speichern fehlgeschlagen: Der Wert wurde abgelehnt oder steht in Konflikt. Bitte überprüfen."
470
+ },
471
+ it: {
472
+ "card.title": "Livelli di ragionamento",
473
+ "family.title": "Impostazioni plugin Qizi",
474
+ "card.description": "Scegli Auto nel selettore del modello: il plugin pianifica low / high / max in base alla cronologia delle chiamate degli strumenti prima di inviare l'effort all'API. Qui configuri il livello predefinito, i limiti dello scheduler e le capacità per modello (livello → valore wire inviato al gateway).",
475
+ "card.level": "Livello predefinito",
476
+ "card.level.off": "off — disabilita il ragionamento (solo manuale, mai scelto automaticamente)",
477
+ "card.level.on": "on — abilita il ragionamento (solo modelli a commutazione; invia enable_thinking, mai un effort)",
478
+ "card.level.minimal": "minimal — minimo (compiti molto leggeri)",
479
+ "card.level.low": "low — basso (i round economici restano economici)",
480
+ "card.level.medium": "medium — medio",
481
+ "card.level.high": "high — alto (predefinito ufficiale)",
482
+ "card.level.xhigh": "xhigh — molto alto",
483
+ "card.level.max": "max — massimo (compiti pesanti)",
484
+ "card.level.auto": "auto — pianificazione dalla cronologia strumenti (predefinito)",
485
+ "card.enabled": "Abilitato",
486
+ "card.allowDowngrade": "Consenti declassamento (auto può scendere a low)",
487
+ "card.allowUpgrade": "Consenti avanzamento (auto può salire a max)",
488
+ "card.unavailable": "Namespace delle impostazioni non disponibile: assicurati che dsh-thinking-levels sia integrato in questo profilo.",
489
+ "card.readonly": "Sola lettura",
490
+ "card.capabilities": "Capacità del modello (provider personalizzati llm-pi-ai)",
491
+ "card.capabilities.hint": "Legge e scrive direttamente la configurazione llm-pi-ai: spunta un livello e inserisci il valore esatto inviato al gateway (es. high → ultra); lasciare off vuoto significa «non inviare». Vision controlla l'input immagine; l'interruttore di ragionamento guida enable_thinking; thinkingFormat sceglie la serializzazione wire.",
492
+ "card.capabilities.empty": "Nessun provider personalizzato ha modelli configurati in llm-pi-ai. Aggiungi prima un provider e dei modelli in Impostazioni → Modelli.",
493
+ "card.capabilities.unavailable": "Il namespace delle impostazioni llm-pi-ai non è disponibile.",
494
+ "card.capabilities.none": "(nessun modello)",
495
+ "card.capabilities.search": "Cerca modelli per nome o ID…",
496
+ "card.capabilities.noMatches": "Nessun modello corrispondente",
497
+ "card.capabilities.quickSettings": "Impostazioni rapide",
498
+ "card.capabilities.presetOfficial": "Applica a tutti: Off / High / Max (stile ufficiale DeepSeek)",
499
+ "card.capabilities.presetGeneric": "Applica a tutti: Off / Low / Medium / High (generico)",
500
+ "card.capabilities.vendor": "Provider",
501
+ "card.capabilities.developerRole": "Il gateway rifiuta il ruolo developer",
502
+ "card.capabilities.developerRoleHint": "Interruttore di compatibilità ufficiale (dsh ≥ v0.1.0-rc.8): scrive compat.supportsDeveloperRole: false a livello di rotta così il prompt di sistema viene inviato come ruolo system — corregge l'errore Unexpected message role 400 su gateway vLLM / SGLang. Deselezionare elimina il campo e ripristina l'ereditarietà.",
503
+ "card.capabilities.expandProvider": "Espandi provider",
504
+ "card.capabilities.collapseProvider": "Comprimi provider",
505
+ "card.capabilities.openModelSettings": "Apri impostazioni modello",
506
+ "card.capabilities.closeModelSettings": "Comprimi impostazioni modello",
507
+ "card.capabilities.vision": "Modello vision",
508
+ "card.capabilities.thinking": "Modello di ragionamento",
509
+ "card.capabilities.supportsEffort": "Supporta think effort",
510
+ "card.capabilities.efforts": "Livelli di ragionamento (spunta, poi inserisci il valore wire)",
511
+ "card.capabilities.wirePlaceholder": "Valore wire, es. ultra",
512
+ "card.capabilities.offPlaceholder": "Vuoto = non inviare",
513
+ "card.capabilities.atLeastThinking": "Seleziona almeno un livello di ragionamento (diverso da off)",
514
+ "card.capabilities.applyLevel": "Applica livelli",
515
+ "card.capabilities.restoreDefault": "Ripristina predefiniti",
516
+ "card.capabilities.unsaved": "Non salvato",
517
+ "card.capabilities.saveChanges": "Salva modifiche",
518
+ "card.capabilities.saved": "Salvato",
519
+ "card.capabilities.thinkingFormat": "Formato di ragionamento",
520
+ "card.capabilities.thinkingFormat.inherit": "Eredita",
521
+ "card.capabilities.contextWindow": "Limite finestra di contesto",
522
+ "card.capabilities.contextCustomPlaceholder": "Intero personalizzato, es. 256000",
523
+ "card.capabilities.contextClear": "Cancella",
524
+ "card.capabilities.contextInteger": "La lunghezza del contesto deve essere un intero (2000-1000000)",
525
+ "card.capabilities.contextRange": "La lunghezza del contesto deve essere compresa tra 2000 e 1000000",
526
+ "card.capabilities.contextHint": "Scegli un predefinito o inserisci un intero (2000–1000000); scritto in llm-pi-ai per la pressione/compressione del contesto e applicato alla richiesta successiva senza riavvio.",
527
+ "input.context.title": "Finestra di contesto",
528
+ "input.context.globalHint": "Si applica globalmente a tutte le sessioni che usano questo modello (Cancella ripristina il predefinito)",
529
+ "input.context.unset": "Non impostato",
530
+ "input.context.custom": "Personalizzato",
531
+ "input.context.noModel": "Nessun modello di sessione",
532
+ "input.context.customPlaceholder": "Intero personalizzato, es. 256000",
533
+ "input.context.apply": "Applica",
534
+ "input.context.clear": "Cancella",
535
+ "input.context.integer": "La lunghezza del contesto deve essere un intero (2000-1000000)",
536
+ "input.context.range": "La lunghezza del contesto deve essere compresa tra 2000 e 1000000",
537
+ "model.panel.choose": "Scegli modello",
538
+ "model.panel.loading": "Caricamento directory modelli…",
539
+ "model.panel.empty": "Nessun modello disponibile",
540
+ "model.panel.window": "Finestra",
541
+ "model.panel.noTarget": "Nessuna voce di configurazione scrivibile per questo modello",
542
+ "model.panel.unavailable": "La directory dei modelli non è disponibile per questa sessione",
543
+ "input.effort.title": "Sforzo di ragionamento",
544
+ "input.effort.default": "Predefinito del provider",
545
+ "card.capabilities.failed": "Salvataggio non riuscito: il valore è stato rifiutato o è in conflitto. Verifica."
546
+ },
547
+ ru: {
548
+ "card.title": "Уровни мышления",
549
+ "family.title": "Настройки плагинов Qizi",
550
+ "card.description": "Выберите Auto в селекторе модели: плагин планирует low / high / max по истории вызовов инструментов перед отправкой effort в API. Здесь настраивается уровень по умолчанию, границы планировщика и возможности модели (уровень → значение, отправляемое шлюзу).",
551
+ "card.level": "Уровень по умолчанию",
552
+ "card.level.off": "off — отключить мышление (только вручную, никогда не выбирается автоматически)",
553
+ "card.level.on": "on — включить мышление (только модели с переключателем; отправляет enable_thinking, без effort)",
554
+ "card.level.minimal": "minimal — минимальный (очень лёгкие задачи)",
555
+ "card.level.low": "low — низкий (дешёвые раунды остаются дешёвыми)",
556
+ "card.level.medium": "medium — средний",
557
+ "card.level.high": "high — высокий (официальное значение по умолчанию)",
558
+ "card.level.xhigh": "xhigh — особо высокий",
559
+ "card.level.max": "max — максимальный (тяжёлые задачи)",
560
+ "card.level.auto": "auto — планирование по истории инструментов (по умолчанию)",
561
+ "card.enabled": "Включено",
562
+ "card.allowDowngrade": "Разрешить понижение (auto может снизить до low)",
563
+ "card.allowUpgrade": "Разрешить повышение (auto может поднять до max)",
564
+ "card.unavailable": "Пространство имён настроек недоступно: убедитесь, что dsh-thinking-levels подключён к этому профилю.",
565
+ "card.readonly": "Только чтение",
566
+ "card.capabilities": "Возможности модели (пользовательские провайдеры llm-pi-ai)",
567
+ "card.capabilities.hint": "Напрямую читает и пишет конфигурацию llm-pi-ai: отметьте уровень и введите точное значение, отправляемое шлюзу (напр. high → ultra); пустое поле off означает «не отправлять». Vision управляет вводом изображений; переключатель мышления управляет enable_thinking; thinkingFormat задаёт формат сериализации wire.",
568
+ "card.capabilities.empty": "Ни один пользовательский провайдер не имеет настроенных моделей в llm-pi-ai. Сначала добавьте провайдер и модели в Настройки → Модели.",
569
+ "card.capabilities.unavailable": "Пространство имён настроек llm-pi-ai недоступно.",
570
+ "card.capabilities.none": "(нет моделей)",
571
+ "card.capabilities.search": "Поиск моделей по имени или ID…",
572
+ "card.capabilities.noMatches": "Нет подходящих моделей",
573
+ "card.capabilities.quickSettings": "Быстрые настройки",
574
+ "card.capabilities.presetOfficial": "Применить ко всем: Off / High / Max (официальный стиль DeepSeek)",
575
+ "card.capabilities.presetGeneric": "Применить ко всем: Off / Low / Medium / High (общий)",
576
+ "card.capabilities.vendor": "Провайдер",
577
+ "card.capabilities.developerRole": "Шлюз отклоняет роль developer",
578
+ "card.capabilities.developerRoleHint": "Официальный переключатель совместимости (dsh ≥ v0.1.0-rc.8): записывает compat.supportsDeveloperRole: false на уровне маршрута, чтобы системный промпт отправлялся с ролью system — исправляет Unexpected message role 400 на шлюзах vLLM / SGLang. Снятие флажка удаляет поле и восстанавливает наследование.",
579
+ "card.capabilities.expandProvider": "Развернуть провайдер",
580
+ "card.capabilities.collapseProvider": "Свернуть провайдер",
581
+ "card.capabilities.openModelSettings": "Открыть настройки модели",
582
+ "card.capabilities.closeModelSettings": "Свернуть настройки модели",
583
+ "card.capabilities.vision": "Модель с vision",
584
+ "card.capabilities.thinking": "Модель с мышлением",
585
+ "card.capabilities.supportsEffort": "Поддерживает think effort",
586
+ "card.capabilities.efforts": "Уровни мышления (отметьте, затем введите значение wire)",
587
+ "card.capabilities.wirePlaceholder": "Значение wire, напр. ultra",
588
+ "card.capabilities.offPlaceholder": "Пусто = не отправлять",
589
+ "card.capabilities.atLeastThinking": "Выберите хотя бы один уровень мышления (кроме off)",
590
+ "card.capabilities.applyLevel": "Применить уровни",
591
+ "card.capabilities.restoreDefault": "Восстановить значения по умолчанию",
592
+ "card.capabilities.unsaved": "Не сохранено",
593
+ "card.capabilities.saveChanges": "Сохранить изменения",
594
+ "card.capabilities.saved": "Сохранено",
595
+ "card.capabilities.thinkingFormat": "Формат мышления",
596
+ "card.capabilities.thinkingFormat.inherit": "Наследовать",
597
+ "card.capabilities.contextWindow": "Лимит контекстного окна",
598
+ "card.capabilities.contextCustomPlaceholder": "Пользовательское целое число, напр. 256000",
599
+ "card.capabilities.contextClear": "Очистить",
600
+ "card.capabilities.contextInteger": "Длина контекста должна быть целым числом (2000-1000000)",
601
+ "card.capabilities.contextRange": "Длина контекста должна быть от 2000 до 1000000",
602
+ "card.capabilities.contextHint": "Выберите пресет или введите целое число (2000–1000000); записывается в llm-pi-ai для давления/сжатия контекста и применяется к следующему запросу без перезапуска.",
603
+ "input.context.title": "Контекстное окно",
604
+ "input.context.globalHint": "Применяется глобально ко всем сессиям с этой моделью (Очистить восстанавливает значение по умолчанию)",
605
+ "input.context.unset": "Не задано",
606
+ "input.context.custom": "Пользовательское",
607
+ "input.context.noModel": "Модель сессии ещё не выбрана",
608
+ "input.context.customPlaceholder": "Пользовательское целое число, напр. 256000",
609
+ "input.context.apply": "Применить",
610
+ "input.context.clear": "Очистить",
611
+ "input.context.integer": "Длина контекста должна быть целым числом (2000-1000000)",
612
+ "input.context.range": "Длина контекста должна быть от 2000 до 1000000",
613
+ "model.panel.choose": "Выбрать модель",
614
+ "model.panel.loading": "Загрузка каталога моделей…",
615
+ "model.panel.empty": "Нет доступных моделей",
616
+ "model.panel.window": "Окно",
617
+ "model.panel.noTarget": "Нет записываемой записи конфигурации для этой модели",
618
+ "model.panel.unavailable": "Каталог моделей недоступен для этой сессии",
619
+ "input.effort.title": "Усилие рассуждения",
620
+ "input.effort.default": "Значение провайдера по умолчанию",
621
+ "card.capabilities.failed": "Ошибка сохранения: значение отклонено или конфликтует. Проверьте его."
622
+ },
623
+ es: {
624
+ "card.title": "Niveles de razonamiento",
625
+ "family.title": "Configuración de plugins Qizi",
626
+ "card.description": "Elige Auto en el selector de modelo: el plugin planifica low / high / max según el historial de llamadas de herramientas antes de enviar el effort a la API. Aquí configuras el nivel predeterminado, los límites del planificador y las capacidades por modelo (nivel → valor wire enviado al gateway).",
627
+ "card.level": "Nivel predeterminado",
628
+ "card.level.off": "off — desactivar razonamiento (solo manual, nunca seleccionado automáticamente)",
629
+ "card.level.on": "on — activar razonamiento (solo modelos de conmutación; envía enable_thinking, nunca un effort)",
630
+ "card.level.minimal": "minimal — mínimo (tareas muy ligeras)",
631
+ "card.level.low": "low — bajo (las rondas económicas siguen siendo económicas)",
632
+ "card.level.medium": "medium — medio",
633
+ "card.level.high": "high — alto (predeterminado oficial)",
634
+ "card.level.xhigh": "xhigh — extra alto",
635
+ "card.level.max": "max — máximo (tareas pesadas)",
636
+ "card.level.auto": "auto — planificación desde el historial de herramientas (predeterminado)",
637
+ "card.enabled": "Activado",
638
+ "card.allowDowngrade": "Permitir degradación (auto puede bajar a low)",
639
+ "card.allowUpgrade": "Permitir mejora (auto puede subir a max)",
640
+ "card.unavailable": "Espacio de nombres de configuración no disponible: asegúrate de que dsh-thinking-levels esté ensamblado en este perfil.",
641
+ "card.readonly": "Solo lectura",
642
+ "card.capabilities": "Capacidades del modelo (proveedores personalizados llm-pi-ai)",
643
+ "card.capabilities.hint": "Lee y escribe directamente la configuración de llm-pi-ai: marca un nivel e introduce el valor exacto enviado al gateway (ej. high → ultra); dejar off vacío significa «no enviar». Vision controla la entrada de imágenes; el interruptor de razonamiento gestiona enable_thinking; thinkingFormat elige la serialización wire.",
644
+ "card.capabilities.empty": "Ningún proveedor personalizado tiene modelos configurados en llm-pi-ai. Añade primero un proveedor y modelos en Configuración → Modelos.",
645
+ "card.capabilities.unavailable": "El espacio de nombres de configuración de llm-pi-ai no está disponible.",
646
+ "card.capabilities.none": "(sin modelos)",
647
+ "card.capabilities.search": "Buscar modelos por nombre o ID…",
648
+ "card.capabilities.noMatches": "No hay modelos coincidentes",
649
+ "card.capabilities.quickSettings": "Configuración rápida",
650
+ "card.capabilities.presetOfficial": "Aplicar a todos: Off / High / Max (estilo oficial DeepSeek)",
651
+ "card.capabilities.presetGeneric": "Aplicar a todos: Off / Low / Medium / High (genérico)",
652
+ "card.capabilities.vendor": "Proveedor",
653
+ "card.capabilities.developerRole": "El gateway rechaza el rol developer",
654
+ "card.capabilities.developerRoleHint": "Interruptor de compatibilidad oficial (dsh ≥ v0.1.0-rc.8): escribe compat.supportsDeveloperRole: false a nivel de ruta para que el prompt del sistema se envíe con rol system — corrige el error Unexpected message role 400 en gateways vLLM / SGLang. Desmarcar elimina el campo y restaura la herencia.",
655
+ "card.capabilities.expandProvider": "Expandir proveedor",
656
+ "card.capabilities.collapseProvider": "Contraer proveedor",
657
+ "card.capabilities.openModelSettings": "Abrir configuración del modelo",
658
+ "card.capabilities.closeModelSettings": "Contraer configuración del modelo",
659
+ "card.capabilities.vision": "Modelo de visión",
660
+ "card.capabilities.thinking": "Modelo de razonamiento",
661
+ "card.capabilities.supportsEffort": "Soporta think effort",
662
+ "card.capabilities.efforts": "Niveles de razonamiento (marca, luego introduce el valor wire)",
663
+ "card.capabilities.wirePlaceholder": "Valor wire, ej. ultra",
664
+ "card.capabilities.offPlaceholder": "Vacío = no enviar",
665
+ "card.capabilities.atLeastThinking": "Selecciona al menos un nivel de razonamiento (distinto de off)",
666
+ "card.capabilities.applyLevel": "Aplicar niveles",
667
+ "card.capabilities.restoreDefault": "Restaurar valores predeterminados",
668
+ "card.capabilities.unsaved": "Sin guardar",
669
+ "card.capabilities.saveChanges": "Guardar cambios",
670
+ "card.capabilities.saved": "Guardado",
671
+ "card.capabilities.thinkingFormat": "Formato de razonamiento",
672
+ "card.capabilities.thinkingFormat.inherit": "Heredar",
673
+ "card.capabilities.contextWindow": "Límite de ventana de contexto",
674
+ "card.capabilities.contextCustomPlaceholder": "Entero personalizado, ej. 256000",
675
+ "card.capabilities.contextClear": "Borrar",
676
+ "card.capabilities.contextInteger": "La longitud del contexto debe ser un entero (2000-1000000)",
677
+ "card.capabilities.contextRange": "La longitud del contexto debe estar entre 2000 y 1000000",
678
+ "card.capabilities.contextHint": "Elige un ajuste predefinido o introduce un entero (2000–1000000); se escribe en llm-pi-ai para la presión/compresión del contexto y se aplica a la siguiente solicitud sin reiniciar.",
679
+ "input.context.title": "Ventana de contexto",
680
+ "input.context.globalHint": "Se aplica globalmente a todas las sesiones que usan este modelo (Borrar restaura el valor predeterminado)",
681
+ "input.context.unset": "Sin definir",
682
+ "input.context.custom": "Personalizado",
683
+ "input.context.noModel": "Aún no hay modelo de sesión",
684
+ "input.context.customPlaceholder": "Entero personalizado, ej. 256000",
685
+ "input.context.apply": "Aplicar",
686
+ "input.context.clear": "Borrar",
687
+ "input.context.integer": "La longitud del contexto debe ser un entero (2000-1000000)",
688
+ "input.context.range": "La longitud del contexto debe estar entre 2000 y 1000000",
689
+ "model.panel.choose": "Elegir modelo",
690
+ "model.panel.loading": "Cargando el directorio de modelos…",
691
+ "model.panel.empty": "No hay modelos disponibles",
692
+ "model.panel.window": "Ventana",
693
+ "model.panel.noTarget": "No hay entrada de configuración escribible para este modelo",
694
+ "model.panel.unavailable": "El directorio de modelos no está disponible para esta sesión",
695
+ "input.effort.title": "Esfuerzo de razonamiento",
696
+ "input.effort.default": "Predeterminado del proveedor",
697
+ "card.capabilities.failed": "Error al guardar: el valor fue rechazado o está en conflicto. Verifícalo."
698
+ }
308
699
  };
309
700
  /** The multi-level context-window presets, in ascending order. */
310
701
  const CONTEXT_WINDOW_PRESETS = [
@@ -405,6 +796,13 @@ window.__ModuleLoader__.load({
405
796
  const DEEPSEEK_DEFAULT_WINDOW = 1e6;
406
797
  /** Slider stop an unset window parks on: the thumb needs a position, the readout stays "unset". */
407
798
  const UNSET_STOP_INDEX = CONTEXT_WINDOW_PRESETS.findIndex((preset) => preset.value === 256e3);
799
+ /** Snapshot shown when the session's directory face is unavailable. */
800
+ const UNAVAILABLE_STATE = {
801
+ status: "loading",
802
+ groups: [],
803
+ current: null,
804
+ error: null
805
+ };
408
806
  const rootStyle = {
409
807
  position: "relative",
410
808
  display: "inline-flex"
@@ -415,7 +813,7 @@ window.__ModuleLoader__.load({
415
813
  gap: "6px",
416
814
  height: "26px",
417
815
  padding: "0 10px",
418
- background: "var(--dsw-alias-bg-surface, #fff)",
816
+ background: "var(--dsw-alias-bg-layer-1)",
419
817
  color: "var(--dsw-alias-label-primary)",
420
818
  border: "1px solid var(--dsw-alias-border-l2)",
421
819
  borderRadius: "8px",
@@ -430,6 +828,13 @@ window.__ModuleLoader__.load({
430
828
  overflow: "hidden",
431
829
  textOverflow: "ellipsis"
432
830
  };
831
+ const triggerEffortStyle = {
832
+ flex: "0 0 auto",
833
+ maxWidth: "72px",
834
+ overflow: "hidden",
835
+ textOverflow: "ellipsis",
836
+ color: "var(--dsw-alias-label-tertiary)"
837
+ };
433
838
  const chevronStyle = {
434
839
  flex: "0 0 auto",
435
840
  fontSize: "9px",
@@ -442,7 +847,7 @@ window.__ModuleLoader__.load({
442
847
  zIndex: 1200,
443
848
  width: "320px",
444
849
  padding: "8px",
445
- background: "var(--dsw-alias-bg-layer-3, rgba(127,127,127,0.05))",
850
+ background: "var(--dsw-alias-bg-layer-3)",
446
851
  color: "var(--dsw-alias-label-primary)",
447
852
  border: "1px solid var(--dsw-alias-border-l2)",
448
853
  borderRadius: "10px",
@@ -487,14 +892,29 @@ window.__ModuleLoader__.load({
487
892
  color: "var(--dsw-alias-label-tertiary)",
488
893
  fontSize: "11px"
489
894
  };
895
+ /** The model-line row CONTAINER: highlight surface + flex parent of pick/select/chip.
896
+ * Wraps so the inline window editor (a flex item too) takes its own full line. */
490
897
  const modelRowStyle$1 = {
491
898
  display: "flex",
899
+ flexWrap: "wrap",
492
900
  alignItems: "center",
493
901
  gap: "6px",
494
902
  width: "100%",
495
- padding: "6px 8px 6px 18px",
903
+ borderRadius: "6px"
904
+ };
905
+ const modelRowActiveStyle = {
906
+ ...modelRowStyle$1,
907
+ background: "var(--dsw-alias-state-business-primary-weak, var(--dsw-alias-interactive-bg-hover, transparent))"
908
+ };
909
+ /** The pick button inside the row: name/description/✓, keeps the row's old padding. */
910
+ const modelPickStyle = {
911
+ flex: "1 1 auto",
912
+ minWidth: 0,
913
+ display: "flex",
914
+ alignItems: "center",
915
+ gap: "6px",
916
+ padding: "6px 4px 6px 18px",
496
917
  border: "none",
497
- borderRadius: "6px",
498
918
  background: "transparent",
499
919
  color: "var(--dsw-alias-label-primary)",
500
920
  font: "inherit",
@@ -502,10 +922,6 @@ window.__ModuleLoader__.load({
502
922
  cursor: "pointer",
503
923
  textAlign: "left"
504
924
  };
505
- const modelRowActiveStyle = {
506
- ...modelRowStyle$1,
507
- background: "var(--dsw-alias-state-business-primary-weak, rgba(77,107,254,0.10))"
508
- };
509
925
  const modelCopyStyle = {
510
926
  flex: "1 1 auto",
511
927
  minWidth: 0,
@@ -518,13 +934,6 @@ window.__ModuleLoader__.load({
518
934
  textOverflow: "ellipsis",
519
935
  whiteSpace: "nowrap"
520
936
  };
521
- const modelDescriptionStyle = {
522
- overflow: "hidden",
523
- textOverflow: "ellipsis",
524
- whiteSpace: "nowrap",
525
- fontSize: "11px",
526
- color: "var(--dsw-alias-label-tertiary)"
527
- };
528
937
  const checkStyle = {
529
938
  flex: "0 0 auto",
530
939
  color: "var(--dsw-alias-state-business-primary)"
@@ -535,21 +944,38 @@ window.__ModuleLoader__.load({
535
944
  padding: "0 6px",
536
945
  border: "1px solid var(--dsw-alias-border-l2)",
537
946
  borderRadius: "5px",
538
- background: "var(--dsw-alias-bg-surface, #fff)",
947
+ background: "var(--dsw-alias-bg-layer-1)",
539
948
  color: "var(--dsw-alias-label-secondary)",
540
949
  fontSize: "11px",
541
950
  lineHeight: "16px",
542
951
  fontFamily: "var(--ds-font-family-code, monospace)",
543
952
  fontVariantNumeric: "tabular-nums",
544
953
  cursor: "pointer",
545
- whiteSpace: "nowrap"
954
+ whiteSpace: "nowrap",
955
+ marginRight: "8px"
546
956
  };
547
957
  const chipDisabledStyle = {
548
958
  ...chipStyle,
549
959
  cursor: "default",
550
960
  opacity: .55
551
961
  };
962
+ const selectStyle = {
963
+ flex: "0 0 auto",
964
+ height: "18px",
965
+ maxWidth: "96px",
966
+ padding: "0 2px",
967
+ border: "1px solid var(--dsw-alias-border-l2)",
968
+ borderRadius: "5px",
969
+ background: "var(--dsw-alias-bg-layer-1)",
970
+ color: "var(--dsw-alias-label-secondary)",
971
+ font: "inherit",
972
+ fontSize: "11px",
973
+ lineHeight: "16px",
974
+ cursor: "pointer",
975
+ colorScheme: "dark light"
976
+ };
552
977
  const editorRowStyle = {
978
+ flex: "1 1 100%",
553
979
  display: "flex",
554
980
  alignItems: "center",
555
981
  gap: "6px",
@@ -557,7 +983,7 @@ window.__ModuleLoader__.load({
557
983
  padding: "6px",
558
984
  border: "1px solid var(--dsw-alias-border-l2)",
559
985
  borderRadius: "6px",
560
- background: "var(--dsw-alias-bg-surface, #fff)",
986
+ background: "var(--dsw-alias-bg-layer-1)",
561
987
  fontSize: "12px"
562
988
  };
563
989
  const labelStyle$1 = {
@@ -599,13 +1025,13 @@ window.__ModuleLoader__.load({
599
1025
  padding: "2px 6px",
600
1026
  border: "1px solid var(--dsw-alias-border-l2)",
601
1027
  borderRadius: "5px",
602
- background: "var(--dsw-alias-bg-surface, #fff)",
1028
+ background: "var(--dsw-alias-bg-layer-1)",
603
1029
  color: "var(--dsw-alias-label-primary)",
604
1030
  font: "inherit"
605
1031
  };
606
1032
  const errorStyle = {
607
1033
  flex: "0 0 auto",
608
- color: "var(--dsw-alias-danger, #e5484d)",
1034
+ color: "var(--dsw-alias-state-error-primary)",
609
1035
  fontSize: "11px"
610
1036
  };
611
1037
  const statusStyle = {
@@ -616,8 +1042,8 @@ window.__ModuleLoader__.load({
616
1042
  const errorBannerStyle = {
617
1043
  padding: "6px 8px",
618
1044
  borderRadius: "6px",
619
- background: "var(--dsw-alias-danger-weak, rgba(229,72,77,0.10))",
620
- color: "var(--dsw-alias-danger, #e5484d)",
1045
+ background: "var(--dsw-alias-interactive-bg-hover-danger)",
1046
+ color: "var(--dsw-alias-state-error-primary)",
621
1047
  fontSize: "11px"
622
1048
  };
623
1049
  /** The user-layer `providers` value of the llm-pi-ai namespace, when present. */
@@ -672,7 +1098,7 @@ window.__ModuleLoader__.load({
672
1098
  * @param props - injected directory + config forms, session seat, copy.
673
1099
  */
674
1100
  function ModelPanel({ directory, piAiScope, deepseekScope, t }) {
675
- const state = (0, react.useSyncExternalStore)((listener) => directory.store.subscribe(listener), () => directory.store.getSnapshot());
1101
+ const state = (0, react.useSyncExternalStore)((listener) => directory?.store.subscribe(listener) ?? (() => {}), () => directory?.store.getSnapshot() ?? UNAVAILABLE_STATE);
676
1102
  const piSnapshot = (0, react.useSyncExternalStore)((listener) => piAiScope.subscribe(listener), () => piAiScope.getSnapshot());
677
1103
  const dsSnapshot = (0, react.useSyncExternalStore)((listener) => deepseekScope.subscribe(listener), () => deepseekScope.getSnapshot());
678
1104
  const [open, setOpen] = (0, react.useState)(false);
@@ -686,7 +1112,7 @@ window.__ModuleLoader__.load({
686
1112
  const rootRef = (0, react.useRef)(null);
687
1113
  (0, react.useEffect)(() => {
688
1114
  if (!open) return;
689
- directory.load().catch(() => {});
1115
+ directory?.load().catch(() => {});
690
1116
  }, [directory, open]);
691
1117
  const close = (0, react.useCallback)(() => {
692
1118
  setOpen(false);
@@ -804,7 +1230,7 @@ window.__ModuleLoader__.load({
804
1230
  });
805
1231
  };
806
1232
  const chooseModel = (provider, model) => {
807
- if (busy) return;
1233
+ if (busy || directory === void 0) return;
808
1234
  setBusy(true);
809
1235
  directory.select({
810
1236
  provider,
@@ -816,7 +1242,24 @@ window.__ModuleLoader__.load({
816
1242
  setBusy(false);
817
1243
  });
818
1244
  };
1245
+ /** Commit one model line's reasoning effort; empty string = provider default (omit the field). */
1246
+ const chooseEffort = (provider, model, effort) => {
1247
+ if (busy || directory === void 0) return;
1248
+ setBusy(true);
1249
+ directory.select({
1250
+ provider,
1251
+ model,
1252
+ ...effort === "" ? {} : { reasoningEffort: effort }
1253
+ }).then(() => {
1254
+ setBusy(false);
1255
+ }).catch(() => {
1256
+ setBusy(false);
1257
+ });
1258
+ };
819
1259
  const triggerLabel = current?.name ?? state.current?.model ?? t("model.panel.choose");
1260
+ const currentReasoning = current?.model.reasoning;
1261
+ const effectiveEffort = state.current?.reasoningEffort ?? currentReasoning?.defaultEffort;
1262
+ const effortLabel = currentReasoning === void 0 ? void 0 : effectiveEffort === void 0 ? t("input.effort.default") : currentReasoning.efforts.find((level) => level.id === effectiveEffort)?.name ?? effectiveEffort;
820
1263
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
821
1264
  ref: rootRef,
822
1265
  style: rootStyle,
@@ -834,13 +1277,20 @@ window.__ModuleLoader__.load({
834
1277
  setError(null);
835
1278
  }
836
1279
  },
837
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
838
- style: triggerNameStyle,
839
- children: triggerLabel
840
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
841
- style: chevronStyle,
842
- children: open ? "▲" : "▼"
843
- })]
1280
+ children: [
1281
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1282
+ style: triggerNameStyle,
1283
+ children: triggerLabel
1284
+ }),
1285
+ effortLabel !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1286
+ style: triggerEffortStyle,
1287
+ children: effortLabel
1288
+ }),
1289
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1290
+ style: chevronStyle,
1291
+ children: open ? "▲" : "▼"
1292
+ })
1293
+ ]
844
1294
  }), open ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
845
1295
  style: backdropStyle,
846
1296
  onClick: close
@@ -851,11 +1301,15 @@ window.__ModuleLoader__.load({
851
1301
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
852
1302
  style: modelsStyle,
853
1303
  children: [
854
- state.status === "loading" && state.groups.length === 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1304
+ directory === void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1305
+ style: statusStyle,
1306
+ children: t("model.panel.unavailable")
1307
+ }),
1308
+ directory !== void 0 && state.status === "loading" && state.groups.length === 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
855
1309
  style: statusStyle,
856
1310
  children: t("model.panel.loading")
857
1311
  }),
858
- state.groups.map((group) => {
1312
+ directory !== void 0 && state.groups.map((group) => {
859
1313
  const isExpanded = expanded.has(group.id);
860
1314
  const name = group.name ?? group.label ?? group.id;
861
1315
  const activeModel = state.current?.provider === group.id ? state.current.model : void 0;
@@ -883,28 +1337,57 @@ window.__ModuleLoader__.load({
883
1337
  const lineWritable = writableLine(group.id, model.id);
884
1338
  const lineWindow = windowOf(group.id, model.id);
885
1339
  const isEditing = editing !== null && editing.provider === group.id && editing.model === model.id;
886
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
887
- type: "button",
888
- role: "option",
889
- "aria-selected": active,
1340
+ const lineEffort = active ? state.current?.reasoningEffort ?? model.reasoning?.defaultEffort : model.reasoning?.defaultEffort;
1341
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
890
1342
  style: active ? modelRowActiveStyle : modelRowStyle$1,
891
- disabled: busy,
892
- onClick: () => chooseModel(group.id, model.id),
893
1343
  children: [
894
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
895
- style: modelCopyStyle,
1344
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
1345
+ type: "button",
1346
+ role: "option",
1347
+ "aria-selected": active,
1348
+ style: modelPickStyle,
1349
+ disabled: busy,
1350
+ onClick: () => chooseModel(group.id, model.id),
896
1351
  children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
897
- style: modelNameStyle,
898
- children: model.name
899
- }), model.description !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
900
- style: modelDescriptionStyle,
901
- children: model.description
1352
+ style: modelCopyStyle,
1353
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1354
+ style: modelNameStyle,
1355
+ children: model.name
1356
+ })
1357
+ }), active && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1358
+ style: checkStyle,
1359
+ "aria-hidden": "true",
1360
+ children: "✓"
902
1361
  })]
903
1362
  }),
904
- active && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
905
- style: checkStyle,
906
- "aria-hidden": "true",
907
- children: "✓"
1363
+ model.reasoning !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("select", {
1364
+ "aria-label": t("input.effort.title"),
1365
+ title: t("input.effort.title"),
1366
+ style: selectStyle,
1367
+ disabled: busy,
1368
+ value: lineEffort ?? "",
1369
+ onClick: (event) => event.stopPropagation(),
1370
+ onChange: (event) => {
1371
+ event.stopPropagation();
1372
+ const value = event.currentTarget.value;
1373
+ const target = value === "" ? model.reasoning?.defaultEffort : value;
1374
+ if (target !== void 0) chooseEffort(group.id, model.id, target);
1375
+ },
1376
+ children: [
1377
+ model.reasoning.defaultEffort !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
1378
+ value: "",
1379
+ children: t("input.effort.default")
1380
+ }),
1381
+ model.reasoning.defaultEffort === void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
1382
+ value: "",
1383
+ hidden: true,
1384
+ children: t("input.effort.default")
1385
+ }),
1386
+ model.reasoning.efforts.map((level) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
1387
+ value: level.id,
1388
+ children: level.name
1389
+ }, level.id))
1390
+ ]
908
1391
  }),
909
1392
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
910
1393
  role: "button",
@@ -929,100 +1412,101 @@ window.__ModuleLoader__.load({
929
1412
  openEditor(group.id, model.id);
930
1413
  },
931
1414
  children: lineWindow === void 0 ? t("input.context.unset") : formatContextWindow(lineWindow)
932
- })
933
- ]
934
- }), isEditing && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
935
- style: editorRowStyle,
936
- children: [
937
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
938
- style: labelStyle$1,
939
- title: t("input.context.globalHint"),
940
- children: t("model.panel.window")
941
1415
  }),
942
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
943
- type: "range",
944
- min: 0,
945
- max: CONTEXT_WINDOW_PRESETS.length - 1,
946
- step: 1,
947
- value: draft ?? stopIndexOf(lineWindow),
948
- disabled: busy,
949
- "aria-label": t("input.context.title"),
950
- style: sliderStyle,
951
- onChange: (event) => {
952
- setDraft(Number(event.currentTarget.value));
953
- },
954
- onPointerUp: () => {
955
- if (draft === null) return;
956
- commitWindow(group.id, model.id, CONTEXT_WINDOW_PRESETS[draft]?.value);
957
- },
958
- onKeyUp: () => {
959
- if (draft === null) return;
960
- commitWindow(group.id, model.id, CONTEXT_WINDOW_PRESETS[draft]?.value);
961
- }
962
- }),
963
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
964
- style: valueStyle,
965
- children: draft === null ? lineWindow === void 0 ? t("input.context.unset") : formatContextWindow(lineWindow) : formatContextWindow(CONTEXT_WINDOW_PRESETS[draft]?.value ?? 0)
966
- }),
967
- custom ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
968
- type: "text",
969
- inputMode: "numeric",
970
- value: raw,
971
- disabled: busy,
972
- placeholder: t("input.context.customPlaceholder"),
973
- "aria-label": t("input.context.customPlaceholder"),
974
- style: inputStyle,
975
- onChange: (event) => {
976
- setRaw(event.currentTarget.value);
977
- },
978
- onKeyDown: (event) => {
979
- if (event.key === "Enter") applyCustom();
980
- }
981
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
982
- type: "button",
983
- disabled: busy,
984
- style: actionButtonStyle,
985
- onClick: applyCustom,
986
- children: t("input.context.apply")
987
- })] }) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
988
- type: "button",
989
- disabled: busy,
990
- "aria-label": t("input.context.custom"),
991
- title: t("input.context.custom"),
992
- style: actionButtonStyle,
993
- onClick: () => {
994
- setCustom(true);
995
- setError(null);
996
- },
997
- children: "⋯"
998
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
999
- type: "button",
1000
- disabled: busy || lineWindow === void 0,
1001
- style: {
1002
- ...actionButtonStyle,
1003
- opacity: lineWindow === void 0 ? .55 : 1
1004
- },
1005
- onClick: () => {
1006
- setDraft(null);
1007
- setError(null);
1008
- commitWindow(group.id, model.id, void 0);
1009
- },
1010
- children: t("input.context.clear")
1011
- })] }),
1012
- error !== null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1013
- style: errorStyle,
1014
- children: error
1416
+ isEditing && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1417
+ style: editorRowStyle,
1418
+ children: [
1419
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1420
+ style: labelStyle$1,
1421
+ title: t("input.context.globalHint"),
1422
+ children: t("model.panel.window")
1423
+ }),
1424
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
1425
+ type: "range",
1426
+ min: 0,
1427
+ max: CONTEXT_WINDOW_PRESETS.length - 1,
1428
+ step: 1,
1429
+ value: draft ?? stopIndexOf(lineWindow),
1430
+ disabled: busy,
1431
+ "aria-label": t("input.context.title"),
1432
+ style: sliderStyle,
1433
+ onChange: (event) => {
1434
+ setDraft(Number(event.currentTarget.value));
1435
+ },
1436
+ onPointerUp: () => {
1437
+ if (draft === null) return;
1438
+ commitWindow(group.id, model.id, CONTEXT_WINDOW_PRESETS[draft]?.value);
1439
+ },
1440
+ onKeyUp: () => {
1441
+ if (draft === null) return;
1442
+ commitWindow(group.id, model.id, CONTEXT_WINDOW_PRESETS[draft]?.value);
1443
+ }
1444
+ }),
1445
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1446
+ style: valueStyle,
1447
+ children: draft === null ? lineWindow === void 0 ? t("input.context.unset") : formatContextWindow(lineWindow) : formatContextWindow(CONTEXT_WINDOW_PRESETS[draft]?.value ?? 0)
1448
+ }),
1449
+ custom ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
1450
+ type: "text",
1451
+ inputMode: "numeric",
1452
+ value: raw,
1453
+ disabled: busy,
1454
+ placeholder: t("input.context.customPlaceholder"),
1455
+ "aria-label": t("input.context.customPlaceholder"),
1456
+ style: inputStyle,
1457
+ onChange: (event) => {
1458
+ setRaw(event.currentTarget.value);
1459
+ },
1460
+ onKeyDown: (event) => {
1461
+ if (event.key === "Enter") applyCustom();
1462
+ }
1463
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1464
+ type: "button",
1465
+ disabled: busy,
1466
+ style: actionButtonStyle,
1467
+ onClick: applyCustom,
1468
+ children: t("input.context.apply")
1469
+ })] }) : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1470
+ type: "button",
1471
+ disabled: busy,
1472
+ "aria-label": t("input.context.custom"),
1473
+ title: t("input.context.custom"),
1474
+ style: actionButtonStyle,
1475
+ onClick: () => {
1476
+ setCustom(true);
1477
+ setError(null);
1478
+ },
1479
+ children: "⋯"
1480
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1481
+ type: "button",
1482
+ disabled: busy || lineWindow === void 0,
1483
+ style: {
1484
+ ...actionButtonStyle,
1485
+ opacity: lineWindow === void 0 ? .55 : 1
1486
+ },
1487
+ onClick: () => {
1488
+ setDraft(null);
1489
+ setError(null);
1490
+ commitWindow(group.id, model.id, void 0);
1491
+ },
1492
+ children: t("input.context.clear")
1493
+ })] }),
1494
+ error !== null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1495
+ style: errorStyle,
1496
+ children: error
1497
+ })
1498
+ ]
1015
1499
  })
1016
1500
  ]
1017
- })] }, group.id + ":" + model.id);
1501
+ }, group.id + ":" + model.id);
1018
1502
  })] }, group.id);
1019
1503
  }),
1020
- state.status !== "loading" && state.groups.length === 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1504
+ directory !== void 0 && state.status !== "loading" && state.groups.length === 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1021
1505
  style: statusStyle,
1022
1506
  children: t("model.panel.empty")
1023
1507
  })
1024
1508
  ]
1025
- }), state.error !== null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1509
+ }), directory !== void 0 && state.error !== null && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
1026
1510
  style: errorBannerStyle,
1027
1511
  role: "status",
1028
1512
  children: state.error
@@ -2264,7 +2748,7 @@ window.__ModuleLoader__.load({
2264
2748
  t,
2265
2749
  scope,
2266
2750
  piAiScope
2267
- }) : renderSlot("dsh-family.tab", {}, {
2751
+ }) : renderSlot?.("dsh-family.tab", {}, {
2268
2752
  only: active,
2269
2753
  fallback: null
2270
2754
  })
@@ -2287,19 +2771,18 @@ window.__ModuleLoader__.load({
2287
2771
  function apply(ctx) {
2288
2772
  const t = ctx.locale.bind(NS);
2289
2773
  ctx.effect(() => {
2290
- const disposers = [
2291
- ctx.locale.register(NS, {
2292
- zh,
2293
- en
2294
- }),
2295
- ctx.locale.register(NS, "ja", ja),
2296
- ctx.locale.register(NS, "ko", ko)
2297
- ];
2298
- return () => {
2299
- for (const dispose of disposers) dispose();
2300
- };
2774
+ try {
2775
+ return ctx.locale.register(NS, dictionaries);
2776
+ } catch {
2777
+ return () => {};
2778
+ }
2301
2779
  }, "dsh-thinking-levels: dictionaries");
2302
- ctx.inject(["modelDirectories"], (scope) => {
2780
+ ctx.inject([
2781
+ "modelDirectories",
2782
+ "sessions",
2783
+ "remote",
2784
+ "remote.session"
2785
+ ], (scope) => {
2303
2786
  const directories = scope.modelDirectories;
2304
2787
  if (directories === void 0) return;
2305
2788
  ctx.slots.inject("conversation.input.model", function* () {
@@ -2309,8 +2792,14 @@ window.__ModuleLoader__.load({
2309
2792
  priority: -1,
2310
2793
  locale: NS,
2311
2794
  inject: (sessionId) => {
2795
+ let directory;
2796
+ try {
2797
+ directory = directories.directoryFor(sessionId);
2798
+ } catch {
2799
+ directory = void 0;
2800
+ }
2312
2801
  return {
2313
- directory: directories.directoryFor(sessionId),
2802
+ directory,
2314
2803
  piAiScope: ctx.configForms.get("llm-pi-ai"),
2315
2804
  deepseekScope: ctx.configForms.get("llm-deepseek")
2316
2805
  };
@@ -2374,6 +2863,12 @@ window.__ModuleLoader__.load({
2374
2863
  } }
2375
2864
  }, FamilySettingsSection);
2376
2865
  });
2866
+ ctx.slots.inject("plugins.bundle.config", () => ctx.slots.register({
2867
+ name: "plugins.bundle.config",
2868
+ key: "dsh-thinking-levels",
2869
+ locale: NS,
2870
+ inject: sectionInjected
2871
+ }, FamilySettingsSection));
2377
2872
  }
2378
2873
  //#endregion
2379
2874
  exports.apply = apply;