fix: switching a session's model, and put the model row in the composer
- POST /api/session/:id/model takes the reference under `model`; sending it at the top level was rejected with "Missing key at [model]". - The chat now shows the model/agent row above the input (revealed while typing or running, as dsh-Go does) instead of in the app bar; the draft keeps the same row, with its project chip first. - Thinking levels: /api/model's variants become a 思考 chip and sheet; the choice travels as ModelRef.variant on the switch or the create, and the last level per model is remembered on the device. - The model picker groups providers, adds 收藏 and 最近 (device-local), shows each model's context size and reasoning mark, and collapses sections. - The `/` palette is shared by the chat and the draft (new slash_palette widget); the draft lists commands and skills but not the client-local /compact, which needs an existing session. - 0.3.14 (314).
This commit is contained in:
1 parent
fff6562cbc
commit
7f2f454539
12 files changed
+962
-344
No files matched your search
@@ -5,6 +5,19 @@
|
||||
|
||||
---
|
||||
|
||||
## 0.3.14 模型切换修复、输入框模型行、思考强度与模型面板(分支 `flutter`)
|
||||
|
||||
| 项 | 结果 |
|
||||
| --- | --- |
|
||||
| 切换模型报错 | `POST /api/session/:id/model` 的 body 应为 `{model: {id, providerID, variant?}}`,之前把模型对象直接放在顶层,服务端报 `Missing key at ["model"]`;已修正并实测切换成功 |
|
||||
| 输入框模型行 | 参照 dsh-Go:聊天页把模型/智能体从顶栏移到输入框上方,输入框获得焦点、有草稿文字或正在生成时显示;草稿页始终显示同一行(左侧多一个项目 chip)。聊天顶栏只留文件按钮 |
|
||||
| 思考强度 | `/api/model` 的每个模型带 `variants`(v2 的 `{id, settings.reasoningEffort}`)。输入框行在模型有档位时显示「思考·默认/低/中/高/极高」,点开选档;选择以 `ModelRef.variant` 随 `POST /session/:id/model` 或建会话时提交,实测会话的 `model.variant` 变为 `high`。每个模型上次的档位记在本机 |
|
||||
| 模型面板 | 重做 `lib/widgets/model_picker.dart`:按 provider 分组(可折叠)、「收藏」「最近」分组(本机 `shared_preferences`,收藏用星标切换)、每个模型标注上下文大小(如 `200K 上下文`)、推理能力标记、搜索、当前项打勾;智能体分段保留 |
|
||||
| 草稿斜杠 | 斜杠面板抽成共享的 `lib/widgets/slash_palette.dart`(匹配、排序、面板、快捷键),草稿页与聊天页共用;草稿只列 `/api/command` 与 `/api/skill` 的结果,不含需要已有会话的客户端内置 `/compact`;无参命令选中即发送(先建会话再执行命令),带参命令补全名称 |
|
||||
| 版本 | **0.3.14(code 314)** |
|
||||
|
||||
---
|
||||
|
||||
## 0.3.13 草稿会话与分组侧栏(分支 `flutter`)
|
||||
|
||||
| 项 | 结果 |
|
||||
|
||||
Reference in new issue
Block a user