feat: 实现循环防护和安全验证功能
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled

refactor(loop_guard): 为LoopGuard添加Clone派生
feat(capabilities): 实现CapabilityManager.validate()安全验证
fix(agentStore): 添加token用量追踪
chore: 删除未实现的Predictor/Lead HAND.toml文件
style(Credits): 移除假数据并标注开发中状态
refactor(Skills): 动态加载技能卡片
perf(configStore): 为定时任务添加localStorage降级
docs: 更新功能文档和版本变更记录
This commit is contained in:
iven
2026-03-27 07:56:53 +08:00
parent 0d4fa96b82
commit eed347e1a6
14 changed files with 724 additions and 476 deletions

View File

@@ -70,7 +70,7 @@
> ✅ **更新 (2026-03-26)**:
> - 7 个 Hands 有完整 Rust 后端实现 (Browser, Collector, Researcher, Slideshow, Speech, Whiteboard, Quiz)
> - ✅ **审批流程**: Kernel 新增 `pending_approvals` 管理,`hand_approve`/`hand_cancel` Tauri 命令已实现真实审批逻辑
> - ⚠️ **Predictor** 和 **Lead** 仅有 HAND.toml 配置文件,无 Rust 实现
> - ⚠️ **Predictor** 和 **Lead** 已删除(无 Rust 实现,配置文件已清理)
> - ⚠️ **Clip** 需要 FFmpeg**Twitter** 需要 API Key
### 1.7 Tauri 后端
@@ -232,9 +232,9 @@
| **Rust Crates** | **9** (types, memory, runtime, kernel, skills, hands, protocols, pipeline, growth) |
| **SKILL.md 文件** | **78+** |
| 动态发现技能 | 78+ (100%) |
| Hands 总数 | 11 |
| **已实现 Hands** | **7 (64%)** |
| **Kernel 注册 Hands** | **7/9 (78%)** |
| Hands 总数 | 10 |
| **已实现 Hands** | **7 (70%)** |
| **Kernel 注册 Hands** | **7/7 (100%)** |
| **Pipeline 模板** | **5** (教育/营销/法律/研究/生产力) |
| Zustand Store | **18+** |
| Tauri 命令 | **80+** |
@@ -285,6 +285,7 @@ skills hands protocols pipeline growth channels
| 日期 | 版本 | 变更内容 |
|------|------|---------|
| 2026-03-27 | v0.6.1 | **功能完整性修复**: 激活 LoopGuard 循环防护、实现 CapabilityManager.validate() 安全验证、handStore/workflowStore KernelClient 适配器、Credits 标注开发中、Skills 动态化、ScheduledTasks localStorage 降级、token 用量追踪 |
| 2026-03-27 | v0.6.0a | **全面审计更新**:所有成熟度标注调整为实际完成度 (平均 68%),新增清理记录 |
| 2026-03-26 | v0.1.0 | **v1.0 发布准备**:移除 Team/Swarm 功能(~8,100 行Pipeline 替代安全修复CI/CD 建立 |
| 2026-03-26 | v0.5.0 | **Smart Presentation Layer**自动类型检测Chart/Quiz/Slideshow/Document 渲染器PresentationAnalyzer Rust 后端 |
@@ -315,5 +316,12 @@ skills hands protocols pipeline growth channels
| 标记 Wasm/Native SkillMode | 明确标注为尚未实现 |
| 清理 browser/mod.rs | 移除未使用的 re-exports |
| 清理 5 个死代码模块 | pattern_detector, recommender, mesh, persona_evolver, trigger_evaluator |
| 激活 LoopGuard | AgentLoop 循环防护已接入 (warn/block/circuit_breaker) |
| 实现 CapabilityManager.validate() | 安全验证ToolAll+AgentKill、ToolAll+ShellExec(*) 组合拒绝 |
| 删除 Predictor/Lead HAND.toml | 无 Rust 实现的配置文件已彻底删除 |
| Credits.tsx 标注开发中 | 移除假数据,显示"开发中"占位 |
| Skills.tsx 动态化 | 移除硬编码系统技能卡片,改为从 skillsCatalog 动态加载 |
| ScheduledTasks 持久化 | 添加 localStorage 降级,刷新不丢失 |
| Token 用量追踪 | chatStore 新增 addTokenUsage/getTotalTokens |
> **审计说明**: 成熟度等级已根据代码审计调整为实际值。Identity Evolution 标注为 L2 (70%) 是因为其 `dead_code` 属性属于 Tauri 运行时模式(在 Tauri 上下文中实际被调用而非真正的死代码。Reflection Engine L2 (65%) 因核心反思逻辑尚未深度迭代。