feat: remember the last selected model (#2518)

Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
Co-authored-by: yetone <yetoneful@gmail.com>
This commit is contained in:
NekoNekoNiko120
2025-07-28 13:21:49 +08:00
committed by GitHub
parent 7e50de8904
commit 5e4eb8652b
4 changed files with 72 additions and 8 deletions

View File

@@ -64,10 +64,10 @@ local function collect_tool_info(messages)
if use.name == "view" or Utils.is_edit_tool_use(use) then
if use.input.path then
local path = Utils.uniform_path(use.input.path)
tools[use.id] = { kind = use.name == "view" and "view" or "edit", use = use, path = path }
if use.id then tools[use.id] = { kind = use.name == "view" and "view" or "edit", use = use, path = path } end
end
else
tools[use.id] = { kind = "other", use = use }
if use.id then tools[use.id] = { kind = "other", use = use } end
end
goto continue
end