refactor: remove Agent preset system, fix run_command enable bug

- Delete preset-manager.ts and preset-bar.ts
- Clean up all preset references from main.ts, types.d.ts, state.ts
- Remove preset modal HTML and CSS, rename temp-slider/modal-actions classes
- Fix run_command tool not being enabled (missing setToolEnabled call)
This commit is contained in:
thzxx
2026-04-06 15:44:27 +08:00
parent 9e6fce2c3f
commit 18a24a2a59
9 changed files with 15 additions and 559 deletions
-17
View File
@@ -116,21 +116,6 @@ export interface ChatSession {
updatedAt: number;
}
// ── 预设类型(v3.0 废弃,保留用于兼容)──
export interface Preset {
id: string;
name: string;
icon: string;
systemPrompt: string;
temperature: number;
numCtx: number;
think: boolean;
builtIn?: boolean;
createdAt: number;
updatedAt: number;
}
// ── Agent 记忆系统类型 ──
export type MemoryType = 'fact' | 'preference' | 'rule' | 'episode';
@@ -278,8 +263,6 @@ export type StateKey =
| 'historySearchQuery'
| 'temperature'
| 'thinkEnabled'
| 'presets'
| 'activePresetId'
| 'toolCallingEnabled'
| 'runCommandEnabled'
| 'memoryEnabled'