feat(chat): add session-level model picker#360
Open
slicenferqin wants to merge 3 commits intoValueCell-ai:mainfrom
Open
feat(chat): add session-level model picker#360slicenferqin wants to merge 3 commits intoValueCell-ai:mainfrom
slicenferqin wants to merge 3 commits intoValueCell-ai:mainfrom
Conversation
bf42c50 to
dcc71cf
Compare
Open
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary / 摘要
This PR adds a session-level model picker to the chat toolbar.
Users can switch the current session to another allowed model, or reset it back to the agent default model without leaving the chat view.
这个 PR 为聊天工具栏增加了“会话级模型选择”。
用户可以直接在当前会话里切换到其他允许的模型,或者一键恢复为 agent 默认模型,而不需要离开聊天页面。
What Changed / 改动内容
Added session model option loading in the chat store via
models.listAdded current-session model update flow via
sessions.patchSynced
modelandmodelProvidermetadata back into the current session stateAdded a compact model selector to
ChatToolbarAdded zh/en/ja i18n strings for the new UI
Added unit tests for model option normalization and session metadata updates
在 chat store 中接入
models.list,加载可选模型目录在 chat store 中接入
sessions.patch,更新当前会话模型把
model/modelProvider同步回当前会话状态,保证选中态稳定在
ChatToolbar中增加紧凑的模型选择器补充中英日三套文案
增加单测,覆盖模型列表解析与会话元数据更新
Scope / 范围说明
This PR intentionally only covers the session-level model picker part discussed in #339.
It does not include agent switching during new session creation, backup/restore, or broader multi-agent workflow changes.
这个 PR 有意只覆盖 #339 中“会话级模型选择”这一子项。
不包含“新建会话时切换 agent”、备份恢复、或更大范围的多 agent 工作流改动。
Testing / 验证
pnpm run lintpnpm run typecheckpnpm testRelated to #339