feat(ipuaro): add session configuration

- Add SessionConfigSchema with persistIndefinitely, maxHistoryMessages, saveInputHistory
- Implement Session.truncateHistory() method for limiting message history
- Update HandleMessage to support history truncation and input history toggle
- Add config flow through useSession and App components
- Add 19 unit tests for SessionConfigSchema
- Update CHANGELOG.md and ROADMAP.md for v0.22.2
This commit is contained in:
imfozilbek
2025-12-02 01:34:04 +05:00
parent 7f0ec49c90
commit a7669f8947
20 changed files with 336 additions and 72 deletions

View File

@@ -1648,7 +1648,7 @@ interface DiffViewProps {
## Version 0.22.0 - Extended Configuration ⚙️
**Priority:** MEDIUM
**Status:** In Progress (1/5 complete)
**Status:** In Progress (2/5 complete)
### 0.22.1 - Display Configuration ✅
@@ -1670,7 +1670,7 @@ export const DisplayConfigSchema = z.object({
- [x] Configurable stats display
- [x] Unit tests (46 new tests: 20 schema, 24 theme, 2 bell)
### 0.22.2 - Session Configuration
### 0.22.2 - Session Configuration
```typescript
// src/shared/constants/config.ts additions
@@ -1682,10 +1682,10 @@ export const SessionConfigSchema = z.object({
```
**Deliverables:**
- [ ] SessionConfigSchema in config.ts
- [ ] History truncation based on maxHistoryMessages
- [ ] Input history persistence toggle
- [ ] Unit tests
- [x] SessionConfigSchema in config.ts
- [x] History truncation based on maxHistoryMessages
- [x] Input history persistence toggle
- [x] Unit tests (19 new tests)
### 0.22.3 - Context Configuration