## 新增 - 15 条主流供应商预设(Kimi Coding / Moonshot / Anthropic / DeepSeek / 智谱 GLM / z.ai / 阿里百炼 / MiniMax / StepFun / SiliconFlow / Novita / OpenRouter / OpenAI / Google AI Studio / 火山方舟),通过 PresetPickerModal 一键填表 - 供应商余额/套餐查询(卡片底部 UsageFooter):余额类 (DeepSeek / SiliconFlow / OpenRouter / StepFun / Novita) + 套餐类(Kimi For Coding / 智谱 GLM / MiniMax),5min stale TTL + force_refresh + 并发 ≤3 - Rust 端 services/ 模块(balance / coding_plan / usage_types), 参考 cc-switch(MIT,© Jason Young)实现 - query_provider_usage 命令:Rust 端从 config 加载 key, 不经 IPC 序列化 API key - usageKinds 持久化到 SQLite settings(JSON 数组), load 时合并回 config,导出 config.toml 时不写 - detect_provider 启发式:旧用户升级后自动获得账单支持 - save-time 校验:未完成供应商(缺 api_key / base_url / 模型) 保存时弹 confirm 列出原因;新增未提交 back 时静默 drop - docs/PROPOSAL-presets-and-usage.md(v0.4-draft 实施档) - docs/VERIFICATION-CHECKLIST.md(70+ 项手动验证清单) ## 修复 - handleDuplicateProvider 的 alias.slice 漏洞:老数据 非规范 alias 复制不再错位 - handleSelectPreset 不再 auto-save,半成品不会落盘 - handleSwitchProvider 校验取消时自动 refresh 回滚, 不会出现内存改 / 盘没动的脏态 ## 文档 - README / README_EN 致谢段补 cc-switch(预设 + 账单) - README 已知限制与后续建议段(/reload 上游限制调研结论) - i18n 补 5 条校验 key + 11 条预设 UI key + 12 条账单 key 详见 docs/PROPOSAL-presets-and-usage.md 与 docs/VERIFICATION-CHECKLIST.md
36 lines
955 B
TOML
36 lines
955 B
TOML
[package]
|
|
name = "kimiswitch"
|
|
version = "0.6.0"
|
|
description = "Kimi Switch - model config manager"
|
|
authors = ["you"]
|
|
edition = "2021"
|
|
|
|
[build-dependencies]
|
|
tauri-build = { version = "2.0.0", features = [] }
|
|
|
|
[dependencies]
|
|
tauri = { version = "2.0.0", features = ["tray-icon"] }
|
|
tauri-plugin-opener = "2.0.0"
|
|
tauri-plugin-single-instance = "2.0.0"
|
|
serde = { version = "1.0", features = ["derive"] }
|
|
serde_json = "1.0"
|
|
indexmap = { version = "2.2", features = ["serde"] }
|
|
chrono = { version = "0.4", features = ["serde"] }
|
|
anyhow = "1.0"
|
|
regex = "1"
|
|
walkdir = "2"
|
|
fs_extra = "1"
|
|
reqwest = { version = "0.12", features = ["json", "rustls-tls", "stream"], default-features = false }
|
|
futures-util = "0.3"
|
|
dirs = "5.0"
|
|
toml = "0.8"
|
|
rusqlite = { version = "0.32", features = ["bundled", "chrono"] }
|
|
|
|
[lib]
|
|
name = "kimiswitch_lib"
|
|
crate-type = ["staticlib", "cdylib", "rlib"]
|
|
|
|
[features]
|
|
default = ["custom-protocol"]
|
|
custom-protocol = ["tauri/custom-protocol"]
|