feat: add RMA (Relationship Memory Architecture) module v0.6.0

Complete RMA system for tracking relationship dynamics in roleplay:
- 10 new modules in src/rma/ (analyzer, memory-store, phase-manager,
  worldbook-sync, float-panel, confirmation-ui, timeline-view, etc.)
- Three-layer model: phases → memories (4 types) → emotional texture
- Post-processing AI analysis via CHARACTER_MESSAGE_RENDERED hook
- Dynamic world book entry toggling/rewriting
- Floating panel UI with 3 states (expanded/half/minimized)
- User confirmation flow (every_turn/important_only/auto modes)
- Settings panel integration with independent API config
- chat_metadata.cola_rma persistence

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Cola-Echo
2026-03-31 23:23:41 +08:00
parent 621b6bad30
commit 10ea8cc1f4
22 changed files with 2928 additions and 19 deletions

View File

@@ -11,6 +11,26 @@
---
## [0.6.0] - 2026-03-31
### RMA 关系记忆系统(全新模块)
- **新增**`src/rma/` 模块10个文件实现完整的关系记忆架构
- `config-loader.js` — 从角色卡 `extensions.cola_rma_config` 加载 RMA 配置
- `memory-store.js` — 基于 `chat_metadata.cola_rma` 的记忆存储管理
- `analyzer.js` — 后处理 AI 分析引擎,独立 API 调用提取关系变化
- `response-hook.js` — 监听 `CHARACTER_MESSAGE_RENDERED` / `MESSAGE_DELETED` 事件
- `phase-manager.js` — 六阶段关系管理stranger→bond支持回退
- `worldbook-sync.js` — 世界书条目同步(阶段互斥切换、质感改写、事件解锁)
- `confirmation-ui.js` — 用户确认流程(每轮/仅重要/全自动三种模式)
- `float-panel.js` — 悬浮面板 UI展开/半折叠/最小化三态)
- `timeline-view.js` — 记忆时间线视图
- **新增**:四种记忆类型 — breakthrough(⭐)、warmth(💛)、crack(⚡)、revelation(👁)
- **新增**RMA 设置面板 — 启用开关、确认模式选择、面板状态偏好、独立 API 配置
- **新增**`ui/rma-panel.html` — RMA 悬浮面板 HTML 模板
- **新增**RMA 面板 CSS 样式,兼容已有多主题系统
---
## [0.5.0] - 2025-02-13
### 总结世界书拆分功能优化