feat: add preset configurations with built-in and custom presets
Add preset store with three built-in presets (Strict mode, Research only, Full access) and localStorage persistence for custom presets. Integrate preset selector into ConfigSidebar with load, save, and delete actions. Built-in presets cannot be deleted. Closes #14 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
35
implementation-plans/issue-014.md
Normal file
35
implementation-plans/issue-014.md
Normal file
@@ -0,0 +1,35 @@
|
||||
---
|
||||
---
|
||||
|
||||
# Issue #14: Preset configurations
|
||||
|
||||
**Status:** COMPLETED
|
||||
**Issue:** https://git.shahondin1624.de/llm-multiverse/llm-multiverse-ui/issues/14
|
||||
**Branch:** `feature/issue-14-preset-configs`
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
- [x] Save current config as a named preset
|
||||
- [x] Load preset from a list
|
||||
- [x] Delete custom presets
|
||||
- [x] 2-3 built-in default presets shipped:
|
||||
- "Strict mode" — no overrides, restricted tools (FS Write, Run Shell, Run Code, Package Install disabled)
|
||||
- "Research only" — limited tool set for read-only operations (Memory Write, FS Write, Run Code, Run Shell, Package Install disabled)
|
||||
- "Full access" — all overrides relaxed (OverrideLevel.ALL), no tools disabled
|
||||
- [x] Presets persisted in localStorage
|
||||
- [x] Built-in presets cannot be deleted
|
||||
|
||||
## Implementation
|
||||
|
||||
### New Files
|
||||
- `src/lib/stores/presets.svelte.ts` — preset store with built-in presets and localStorage persistence for custom presets
|
||||
|
||||
### Modified Files
|
||||
- `src/lib/components/ConfigSidebar.svelte` — added preset selector section at the top with load, save, and delete functionality
|
||||
|
||||
### Key Decisions
|
||||
- Built-in presets are hardcoded constants, not stored in localStorage
|
||||
- Custom presets stored under `llm-multiverse-presets` localStorage key
|
||||
- Overwriting a custom preset with the same name is allowed; overwriting built-in presets is not
|
||||
- Preset config uses a plain interface (`PresetConfig`) rather than protobuf types for clean serialization
|
||||
- Preset section placed at the top of the sidebar before Override Level, matching the issue instructions
|
||||
Reference in New Issue
Block a user