iven
|
e88c51fd85
|
docs(wiki): 发布前审计数值校准 — TRUTH/CLAUDE/wiki 三端同步
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
TRUTH.md:
- #[test] 433→425, #[tokio::test] 368→309 (2026-04-18 验证)
- Zustand Store 21→26, Admin V2 页面 15→17
- Pipeline YAML 17→18
- Hands 启用 9→7 (6 HAND.toml + _reminder),Whiteboard/Slideshow/Speech 标注开发中
CLAUDE.md §6:
- Hands 12 个能力包 (7 注册 + 3 开发中 + 2 禁用)
- §13 架构快照同步
wiki/index.md:
- 关键数字同步更新
|
2026-04-18 14:09:47 +08:00 |
|
iven
|
e10549a1b9
|
fix: 发布前审计 Batch 2 — Debug遮蔽 + unwrap + 静默吞错 + MCP锁 + 索引 + Config验证
安全:
- LlmConfig 自定义 Debug impl,api_key 显示为 "***REDACTED***"
- tsconfig.json 移除 ErrorBoundary.tsx 排除项(安全关键组件)
- billing/handlers.rs Response builder unwrap → map_err 错误传播
- classroom_commands/mod.rs db_path.parent().unwrap() → ok_or_else
静默吞错:
- approvals.rs 3处 warn→error(审批状态丢失是严重事件)
- events.rs publish() 添加 Event dropped debug 日志
- mcp_transport.rs eprintln→tracing::warn (僵尸进程风险)
- zclaw-growth sqlite.rs 4处迁移:区分 duplicate column name 与真实错误
MCP Transport:
- 合并 stdin+stdout 为单一 Mutex<TransportHandles>
- send_request write-then-read 原子化,防止并发响应错配
数据库:
- 新迁移 20260418000001: idx_rle_created_at + idx_billing_sub_plan + idx_ki_created_by
配置验证:
- SaaSConfig::load() 添加 jwt_expiration_hours>=1, max_connections>0, min<=max
|
2026-04-18 14:09:36 +08:00 |
|
iven
|
f3fb5340b5
|
fix: 发布前审计 Batch 1 — Pipeline 内存泄漏/超时 + Director 死锁 + Rate Limit Worker
Pipeline executor:
- 添加 cleanup() 方法,MAX_COMPLETED_RUNS=100 上限淘汰旧记录
- 每步执行添加 tokio::time::timeout(使用 PipelineSpec.timeout_secs,默认 300s)
- Delay ms 上限 60000,超出 warn 并截断
Director send_to_agent:
- 重构为 oneshot::channel 响应模式,避免 inbox + pending_requests 锁竞争
- 添加 ensure_inbox_reader() 独立任务分发响应到对应 oneshot sender
cleanup_rate_limit Worker:
- 实现 Worker body: DELETE FROM rate_limit_events WHERE created_at < NOW() - INTERVAL '1 hour'
651 tests passed, 0 failed
|
2026-04-18 14:09:16 +08:00 |
|
iven
|
35a11504d7
|
docs(wiki): 审计后续修复记录
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
|
2026-04-18 09:24:25 +08:00 |
|
iven
|
450569dc88
|
fix: 审计后续 3 项修复 — 残留清理 + FTS5 CJK + HTTP 大小限制
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
1. Shell Hands 残留清理 (3处):
- message.rs: 移除过时的 zclaw_hands::slideshow 注释
- user_profiler.rs: slideshow 偏好改为 RecentTopic
- handStore.test.ts: 移除 speech mock 数据 (3→2)
2. zclaw-growth FTS5 CJK 查询修复:
- sanitize_fts_query CJK 路径从精确短语改为 token OR 组合
- "Rust 编程" → "rust" OR "编程" (之前是 "rust 编程" 精确匹配)
- 修复 test_memory_lifecycle + test_semantic_search_ranking
3. WASM HTTP 响应大小限制:
- Content-Length 预检 + 读取后截断 (1MB 上限)
- read_to_string 改为显式错误处理
651 测试全通过,0 失败。
|
2026-04-18 09:23:58 +08:00 |
|
iven
|
3a24455401
|
docs(wiki): 深度审计修复记录
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
|
2026-04-18 09:11:37 +08:00 |
|
iven
|
4e4eefdde1
|
fix: 深度审计修复 — WASM 安全加固 + A2A 编译路径 + 测试编译
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
CRITICAL:
- zclaw_file_read: 路径遍历修复 — 组件级过滤替代前缀检查
- zclaw_http_fetch: SSRF 防护 — URL scheme 白名单 + 私有IP段阻止
- Phase 4A: 移除 zclaw-protocols a2a feature gate, A2A 始终编译
- 移除 kernel/desktop multi-agent feature (不再控制任何代码)
MEDIUM:
- user_profiler: FactCategory cfg(test) 导入修复 (563 测试全通过)
|
2026-04-18 09:11:15 +08:00 |
|
iven
|
0522f2bf95
|
docs: CLAUDE.md 架构快照更新 — 记忆管道 E2E + 最近变更排序
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
|
2026-04-18 08:18:39 +08:00 |
|
iven
|
04f70c797d
|
docs(wiki): Phase 4A/4B 记录 — multi-agent gate 移除 + WASM host 函数
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
|
2026-04-18 08:18:28 +08:00 |
|
iven
|
a685e97b17
|
feat(skills): WASM host 函数真实实现 — zclaw_log/http_fetch/file_read (Phase 4B)
替换 stub 为真实实现:
- zclaw_log: 读取 guest 内存并 log
- zclaw_http_fetch: ureq v3 同步 GET (10s timeout, network_allowed 守卫)
- zclaw_file_read: 沙箱 /workspace 目录读取 (路径校验防逃逸)
添加 ureq v3 workspace 依赖, 25 测试全通过。
|
2026-04-18 08:18:08 +08:00 |
|
iven
|
2037809196
|
refactor(kernel): 移除 multi-agent feature gate — 33处 cfg 全部删除 (Phase 4A)
8 个文件移除 #[cfg(feature = "multi-agent")],zclaw-kernel default features
新增 multi-agent。A2A 路由、agents、adapters 现在始终编译。
|
2026-04-18 08:17:58 +08:00 |
|
iven
|
eaa99a20db
|
feat(ui): Feature Gates 设置页 — 实验性功能开关 (Phase 3B)
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
新增 Settings > 实验性功能 页面:
- 3 个开关: 多 Agent 协作 / WASM 技能沙箱 / 详细工具输出
- localStorage 持久化 + isFeatureEnabled() 公共 API
- 实验性功能警告横幅
- 当前为前端运行时开关,未来可对接 Kernel config
|
2026-04-18 08:05:06 +08:00 |
|
iven
|
a38e91935f
|
docs(wiki): Phase 3A loop_runner 双路径合并记录
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
|
2026-04-17 21:56:34 +08:00 |
|
iven
|
5687dc20e0
|
refactor(runtime): loop_runner 双路径合并 — 统一走 middleware chain (Phase 3A)
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
middleware_chain 从 Option<MiddlewareChain> 改为 MiddlewareChain:
- 移除 6 处 use_middleware 分支 + 2 处 legacy loop_guard inline path
- 移除 loop_guard field + Mutex import + circuit_breaker_triggered 变量
- 空 chain (Default) 行为等价于 middleware path 中的 no-op
- 1154行 → 1023行,净减 131 行
- cargo check --workspace ✓ | cargo test ✓ (排除 desktop 预存编译问题)
|
2026-04-17 21:56:10 +08:00 |
|
iven
|
21c3222ad5
|
docs(wiki): Phase 2A Pipeline 解耦记录
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
|
2026-04-17 20:10:34 +08:00 |
|
iven
|
5381e316f0
|
refactor(pipeline): 移除空的 zclaw-kernel 依赖 (Phase 2A)
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
Pipeline 代码中无任何 zclaw_kernel 引用,依赖声明是遗留物。
移除后编译验证通过: cargo check --workspace --exclude zclaw-saas ✓
|
2026-04-17 20:10:21 +08:00 |
|
iven
|
96294d5b87
|
docs(wiki): Phase 2B saasStore 拆分记录
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
|
2026-04-17 20:05:57 +08:00 |
|
iven
|
e3b6003be2
|
refactor(store): saasStore 拆分为子模块 (Phase 2B)
1025行单文件 → 5个文件 + barrel re-export:
- saas/types.ts (103行) — 类型定义
- saas/shared.ts (93行) — Device ID、常量、recovery probe
- saas/auth.ts (362行) — 登录/注册/登出/恢复/TOTP
- saas/billing.ts (84行) — 计划/订阅/支付
- saas/index.ts (309行) — Store 组装 + 连接/模板/配置
- saasStore.ts (15行) — re-export barrel(外部零改动)
所有 25+ 消费者 import 路径不变,`tsc --noEmit` ✓
|
2026-04-17 20:05:43 +08:00 |
|
iven
|
f9f5472d99
|
docs(wiki): Phase 5 移除空壳 Hand 记录
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
|
2026-04-17 19:56:32 +08:00 |
|
iven
|
cb9e48f11d
|
refactor(hands): 移除空壳 Hand — Whiteboard/Slideshow/Speech (Phase 5)
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
删除 3 个仅含 UI 占位的 Hand,清理 Rust 实现与前端引用:
- Rust: whiteboard.rs(422行) + slideshow.rs(797行) + speech.rs(442行)
- 前端: WhiteboardCanvas + SlideshowRenderer + speech-synth + 相关类型/常量
- 配置: 3 个 HAND.toml
- 净减 ~5400 行,Hands 9→6(启用) + Quiz/Browser/Researcher/Collector/Clip/Twitter/Reminder
|
2026-04-17 19:55:59 +08:00 |
|
iven
|
14fa7e150a
|
docs(wiki): Phase 1 错误体系重构记录
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
|
2026-04-17 19:38:47 +08:00 |
|
iven
|
f9290ea683
|
feat(types): 错误体系重构 — ErrorKind + error code + Serialize
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
Rust (crates/zclaw-types/src/error.rs):
- 新增 ErrorKind enum (17 种) + Serde Serialize/Deserialize
- 新增 error_codes 模块 (稳定错误码 E4040-E5110)
- ZclawError 新增 kind() / code() 方法
- 新增 ErrorDetail struct + Serialize impl
- 保留所有现有变体和构造器 (零破坏性)
- 新增 12 个测试: kind 映射 + code 稳定性 + JSON 序列化
TypeScript (desktop/src/lib/error-types.ts):
- 新增 RustErrorKind / RustErrorDetail 类型定义
- 新增 tryParseRustError() 结构化错误解析
- 新增 classifyRustError() 按 ErrorKind 分类
- classifyError() 优先解析结构化错误,fallback 字符串匹配
- 17 种 ErrorKind → 中文标题映射
验证: cargo check ✓ | tsc ✓ | 62 zclaw-types tests ✓
|
2026-04-17 19:38:19 +08:00 |
|
iven
|
0754ea19c2
|
docs(wiki): Phase 0 修复记录 — 流式事件/CI/中文化
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
|
2026-04-17 18:13:43 +08:00 |
|
iven
|
2cae822775
|
fix: Phase 0 阻碍项修复 — 流式事件错误处理 + CI 排除 + UI 中文化
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
BLK-2: loop_runner.rs 22 处 let _ = tx.send() 全部替换为
if let Err(e) { tracing::warn!(...) },修复流式事件静默丢失问题
BLK-5: 50+ 英文字符串翻译为中文
- HandApprovalModal.tsx (~40处): 风险标签/按钮/状态/表单标签
- ChatArea.tsx: Thinking.../Sending...
- AuditLogsPanel.tsx: 空状态文案
- HandParamsForm.tsx: 空列表提示
- CreateTriggerModal.tsx: 成功提示
- MessageSearch.tsx: 时间筛选/搜索历史
BLK-6: CI/Release workflow 添加 --exclude zclaw-saas
- ci.yml: clippy/test/build 三个步骤
- release.yml: test 步骤
验证: cargo check ✓ | tsc --noEmit ✓
|
2026-04-17 18:12:42 +08:00 |
|
iven
|
93df380ca8
|
docs(wiki): BUG-M4/L1 已修复 + wiki 数字更新
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
- BUG-M4 标记为已修复 (admin_guard_middleware)
- BUG-L1 标记为已验证修复 (代码已统一为 pain_seed_categories)
- E2E 04-17 MEDIUM/LOW 全部关闭
- butler.md/log.md: pain_seeds → pain_seed_categories
|
2026-04-17 11:46:04 +08:00 |
|
iven
|
90340725a4
|
fix(saas): admin_guard_middleware — 非 admin 用户统一返回 403
BUG-M4 修复: 之前非 admin 用户发送 malformed body 到 admin 端点时,
Axum 先反序列化 body 返回 422,绕过了权限检查。
- 新增 admin_guard_middleware (auth/mod.rs) 在中间件层拦截
- account::admin_routes() 拆分 (dashboard 独立)
- billing::admin_routes() + account::admin_routes() 加 guard layer
- 非 admin 用户无论 body 是否合法,统一返回 403
|
2026-04-17 11:45:55 +08:00 |
|
iven
|
b2758d34e9
|
docs(wiki): 添加 04-17 回归验证记录 — 13/13 PASS
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
- Phase 1: 6 项 bug 修复回归全部 PASS (H1/H2/M1/M2/M3/M5)
- Phase 2: Pipeline + Skill 子系统链路全部 PASS
- Phase 3: Butler + 记忆联动全部 PASS
- BUG-L2 Pipeline 反序列化已验证修复
- 记忆系统 381 条记忆, 12 agent 隔离正常
|
2026-04-17 10:45:49 +08:00 |
|
iven
|
a504a40395
|
fix: 7 项 E2E Bug 修复 — Dashboard 404 / 记忆去重 / 记忆注入 / invoice_id / Prompt 版本
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
P0:
- BUG-H1: Dashboard 路由 /api/v1/stats/dashboard → /api/v1/admin/dashboard
P1:
- BUG-H2: viking_add 预检查 content_hash 去重,返回 "deduped" 状态;SqliteStorage 启动时回填已有条目 content_hash
- BUG-M5: saas-relay-client 发送前调用 viking_inject_prompt 注入跨会话记忆
P2:
- BUG-M1: PaymentResult 添加 invoice_id 字段,query_payment_status 返回 invoice_id
- BUG-M2: UpdatePromptRequest 添加内容字段,更新时自动创建新版本并递增 current_version
- BUG-M3: viking_find scope 参数文档化(设计行为,调用方需传 agent scope)
- BUG-M4: Dashboard 路由缺失已修复,handler 层 require_admin 已正确返回 403
P3 (确认已修复/非代码问题):
- BUG-L1: pain_seed_categories 已统一,无 pain_seeds 残留
- BUG-L2: pipeline_create 参数格式正确,E2E 测试方法问题
|
2026-04-17 03:31:06 +08:00 |
|
iven
|
1309101a94
|
fix(ui): Agent 面板信息不随对话更新 — 事件时序 + clones 刷新
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
- streamStore: zclaw:agent-profile-updated 事件从记忆提取前改为 .then() 后触发
- RightPanel: profile 更新事件中新增 loadClones() 刷新 selectedClone 数据
|
2026-04-16 22:57:32 +08:00 |
|
iven
|
0d79993691
|
fix(saas): 3 项 P0 安全/功能修复 + TRUTH.md 数字校准
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
P0-01: Admin ApiKeys 创建功能前后端不匹配
- 前端 service 从 /keys 改回 /tokens(api_tokens 表)
- 前端 UI 字段 {name, expires_days, permissions} 与旧路由匹配
P0-02: 账户锁定检查错误处理
- unwrap_or(false) 改为 map_err + SaasError 传播
- SQL 查询失败时返回错误而非静默跳过锁定检查
P0-03: Logout refresh token 撤销增强
- 新增 access token cookie fallback 提取 account_id
- Tauri 桌面端 Bearer auth 场景下也能撤销 refresh token
TRUTH.md 校准: Tauri 183→190, invoke 95→104, .route() 136→137, 中间件 15→14
|
2026-04-16 22:22:12 +08:00 |
|
iven
|
a0d1392371
|
fix(ui): 5 项 E2E 测试 Bug 修复 — Agent 502 / 错误持久化 / 模型标记 / 侧面板 / 记忆页
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
- BUG-01: createFromTemplate 在 saas-relay 模式下 try-catch 跳过本地 Kernel
- BUG-02: upsertActiveConversation 持久化前剥离 error/streaming/optimistic 字段
- BUG-04: ModelSelector 添加 available 标记,ChatArea 追踪失败模型 ID
- BUG-05: VikingPanel 移除 status?.available 门控,不可用时 disabled + 重连按钮
- BUG-06: 侧面板 tooltip 改为"查看产物文件",空状态增加图标和说明
|
2026-04-16 19:12:21 +08:00 |
|
iven
|
7db9eb29a0
|
fix(butler): useButlerInsights 使用 resolvedAgentId 查询痛点/方案
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
审计发现 useButlerInsights 仍使用原始 agentId("1")查询痛点,
而痛点按 kernel UUID 存储导致空结果。改用 effectiveAgentId
(resolvedAgentId ?? agentId)确保查询路径一致。
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
2026-04-16 17:29:16 +08:00 |
|
iven
|
1e65b56a0f
|
fix(identity): 3 项根因级修复 — Agent ID 映射 + user_profile 读取 + 用户画像 fallback
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
Issue 2: IdentityFile 枚举补全 UserProfile 变体
- get_file()/propose_change()/approve_proposal() 补全 match arm
- identity_get_file/identity_propose_change Tauri 命令支持 user_profile
Issue 1: Agent ID 映射机制
- 新增 resolveKernelAgentId() 工具函数 (带缓存)
- ButlerPanel 使用 kernel UUID 替代 SaaS relay "1" 查询 VikingStorage
Issue 3: 用户画像 fallback 注入
- build_system_prompt 改为 async,identity user_profile 为默认值时
从 VikingStorage preferences 路径查询最近 5 条记忆作为 fallback
- intelligence_hooks 调用处同步加 .await
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
2026-04-16 17:07:38 +08:00 |
|
iven
|
3c01754c40
|
fix(agent): 12 项 agent 对话链路全栈修复
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
深端到端验证发现 12 个问题,6 Phase 全栈修复:
Phase 5 — 快速 UX 修复:
- #9: SimpleSidebar 添加新对话按钮 (SquarePen + useChatStore)
- #5: 模型列表 JOIN provider_keys 过滤无 API Key 的模型
- #11: AgentOnboardingWizard 焦点领域增加 4 行业选项
(医疗健康/教育培训/金融财务/法律合规)
Phase 1 — ButlerPanel 记忆修复:
- #2a: MemorySection URI 从 viking://agent/.../memories/ 修正为 agent://.../
- #2b: "立即分析对话"按钮现在触发 extractAndStoreMemories
Phase 2 — FTS5 中文分词:
- #4: FTS5 tokenizer 从 unicode61 切换到 trigram,原生支持 CJK
- 自动迁移:检测旧 unicode61 表并重建索引
- sanitize_fts_query 支持中文引号短语查询
Phase 3 — 跨会话身份持久化:
- #6-8: 重新启用 USER.md 注入系统提示词 (截断前 10 行)
Phase 4 — Agent 面板同步:
- #1,#10: listClones 从 4 字段扩展到完整映射
(soul/userProfile 解析 nickname/emoji/userName/userRole)
- updateClone 通过 identity 系统同步 nickname→SOUL.md
和 userName/userRole→USER.md
Phase 6 — Agent 创建容错:
- #12: createFromTemplate 增加 SaaS 不可用 fallback
验证: tsc --noEmit ✅ cargo check ✅
|
2026-04-16 09:21:46 +08:00 |
|
iven
|
08af78aa83
|
docs: 2026-04-16 变更记录 — 参数名修复 + 解密自愈 + 设置清理
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
- known-issues.md: 新增 3 条修复记录 (Heartbeat参数/Relay解密/设置清理)
- log.md: 追加 2026-04-16 变更日志
|
2026-04-16 08:06:02 +08:00 |
|
iven
|
b69dc6115d
|
fix(relay): API Key 解密失败自愈 — 启动迁移 + 容错跳过
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
根因: select_best_key 遇到解密失败时直接 500 返回,
不会尝试下一个 key。如果 DB 中有旧的加密格式 key,
整个 relay 请求被阻断。
修复:
- key_pool: 解密失败时 warn + skip 到下一个 key,不再 500
- key_pool: 新增 heal_provider_keys() 启动自愈迁移
- 逐个尝试解密所有加密 key
- 解密成功 → 用当前密钥重新加密(幂等)
- 解密失败 → 标记 is_active=false + warn
- main.rs: 启动时调用自愈迁移(在 TOTP 迁移之后)
|
2026-04-16 02:40:44 +08:00 |
|
iven
|
7dea456fda
|
chore(settings): 删除用量统计和积分详情页面 — 与订阅计费重复
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
UsageStats 和 Credits 功能已被 PricingPage (订阅与计费) 覆盖,
移除冗余页面简化设置导航。
|
2026-04-16 02:07:39 +08:00 |
|
iven
|
f6c5dd21ce
|
fix(heartbeat): Tauri invoke 参数名修正 snake_case → camelCase
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
Tauri 2.x 默认将 Rust snake_case 参数重命名为 camelCase,
前端 invoke 必须使用 camelCase (agentId 而非 agent_id)。
修复 3 处 invoke 调用:
- heartbeat_update_memory_stats (agentId, taskCount, totalEntries, storageSizeBytes)
- heartbeat_record_correction (agentId, correctionType)
- heartbeat_record_interaction (agentId)
|
2026-04-16 00:03:57 +08:00 |
|
iven
|
47250a3b70
|
docs: Heartbeat 统一健康系统文档同步 — TRUTH + wiki + CLAUDE.md §13
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
- TRUTH.md: Tauri 182→183, React 104→105, lib 85→76
- wiki/index.md: 同步关键数字
- wiki/log.md: 追加 2026-04-15 Heartbeat 变更记录
- CLAUDE.md §13: 更新架构快照 + 最近变更
|
2026-04-15 23:22:43 +08:00 |
|
iven
|
215c079d29
|
fix(intelligence): Heartbeat 统一健康系统 — 6处断链修复 + 健康面板 + SaaS自动恢复
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
Rust 后端 (heartbeat.rs):
- 告警实时推送: OnceLock<AppHandle> + Tauri emit heartbeat:alert
- 动态间隔: tokio::select! + Notify 替代不可变 interval
- Config 持久化: update_config 写入 VikingStorage
- heartbeat_init 从 VikingStorage 恢复 config
- 移除 dead code (subscribe, HeartbeatCheckFn)
- Memory stats fallback 分层处理
新增 health_snapshot.rs:
- HealthSnapshot Tauri 命令 — 按需查询引擎/记忆状态
- 注册到 lib.rs invoke_handler
前端修复:
- HeartbeatConfig handleSave 同步到 Rust 后端
- App.tsx 读 localStorage 持久化配置 + heartbeat:alert 监听 + toast
- saasStore 降级后指数退避探测恢复 + saas-recovered 事件
- 新增 HealthPanel.tsx 只读健康面板 (4卡片 + 告警列表)
- SettingsLayout 添加 health 导航入口
清理:
- 删除 intelligence-client/ 目录版 (9文件 -1640行, 单文件版是活跃代码)
|
2026-04-15 23:19:24 +08:00 |
|
iven
|
043824c722
|
perf(runtime): nl_schedule 正则预编译 — 9个 LazyLock 静态替代每次调用编译
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
将 parse_nl_schedule 中 9 个 Regex::new() 从函数内每次调用编译
提升为 std::sync::LazyLock<Regex> 静态变量,首次调用时编译一次,
后续调用直接复用。16 个单元测试全部通过。
|
2026-04-15 13:34:27 +08:00 |
|
iven
|
bd12bdb62b
|
fix(chat): 定时功能审计修复 — 消除重复解析 + ID碰撞 + 输入补全
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
审计发现修复:
- H-01: 存储 ParsedSchedule 避免重复 parse_nl_schedule 调用
- H-03: trigger ID 追加 UUID 片段防止高并发碰撞
- C-02: execute_trigger 验证错误信息明确系统 Hand 必须注册
- M-02: SchedulerService 传递 trigger_name 作为 task_description
- M-01: 添加拦截路径跳过 post_hook 的设计注释
|
2026-04-15 10:02:49 +08:00 |
|
iven
|
28c892fd31
|
fix(chat): 聊天定时功能断链接通 — NlScheduleParser + _reminder Hand
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
接通"写了没接"的定时功能断链:
- NlScheduleParser has_schedule_intent/parse_nl_schedule 接入 agent_chat_stream
- 新增 _reminder 系统 Hand 作为定时触发器桥接
- TriggerManager hand_id 验证对 _ 前缀系统 Hand 放行
- 聊天消息含定时意图时自动拦截,创建触发器并返回确认消息
验证:cargo check 0 error, 49 tests passed,
Tauri MCP "每天早上9点提醒我查房" → cron 0 9 * * * 确认正确显示
|
2026-04-15 09:45:19 +08:00 |
|
iven
|
9715f542b6
|
docs: 发布前冲刺 Day1 文档同步 — TRUTH.md + wiki 数字更新
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
- TRUTH.md: Tauri 182命令、95 invoke、89 @reserved、0孤儿、0 Cargo warnings
- wiki/log.md: 追加 Day1 冲刺记录 (5项修复 + 2项标注)
- wiki/index.md: 更新关键数字与验证日期
|
2026-04-15 02:07:54 +08:00 |
|
iven
|
5121a3c599
|
chore(desktop): Tauri 命令 @reserved 全量标注 — 88个无前端调用命令已标注
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
- 新增 66 个 @reserved 标注 (已有 22 个)
- 覆盖: agent/butler/classroom/hand/mcp/pipeline/skill/trigger/viking/zclaw 等模块
- MCP 命令增加 @connected 注释说明前端接入路径
- @reserved 总数: 89 (含 identity_init)
|
2026-04-15 02:05:58 +08:00 |
|
iven
|
ee1c9ef3ea
|
chore: Cargo warnings 清零 — 39→0 (仅剩 sqlx-postgres 外部依赖警告)
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
- runtime: 移除未使用的 SessionId/Datelike import,修复 unused variable
- intelligence: 模块级 #![allow(dead_code)] 抑制 Hermes 预留代码警告
- mcp.rs/persist.rs/nl_schedule.rs: 标注 #[allow(dead_code)] 保留接口
|
2026-04-15 01:53:11 +08:00 |
|
iven
|
76d36f62a6
|
fix(desktop): 模型自动路由 — 首次登录自动选择可用模型
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
- saasStore: fetchAvailableModels 处理 currentModel 为空的情况,自动选择第一个可用模型
- connectionStore: SaaS relay 连接成功后同步 currentModel 到 conversationStore
- 同时覆盖 Tauri 和浏览器两条 SaaS relay 路径
- 修复首次登录用户需手动选模型的问题
|
2026-04-15 01:45:36 +08:00 |
|
iven
|
be2a136392
|
fix(saas): relay_tasks 超时自动清理 — 每5分钟扫描 processing >10min 标记 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
- scheduler.rs: 新增 start_db_cleanup_tasks 中的 relay 超时清理定时任务
- status=processing 且 updated_at 超过 10 分钟的 relay_task 自动标记为 failed
- 避免 Provider key 禁用后 relay_task 永久停留在 processing 状态
|
2026-04-15 01:41:50 +08:00 |
|
iven
|
76cdfd0c00
|
fix(saas): SSE 用量统计一致性修复 — 回写 usage_records + 消除 relay_requests 双重计数
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
- service.rs: SSE 流结束后回写 usage_records 真实 token (status=success)
- service.rs: spawned task 中调用 increment_usage 统一递增 tokens + relay_requests
- handlers.rs: 移除 SSE 路径的 increment_dimension("relay_requests") 消除双重计数
- 从 request_body 提取 model_id 用于 usage_records 精准归因
|
2026-04-15 01:40:27 +08:00 |
|
iven
|
02a4ba5e75
|
fix(desktop): 替换 require() 为 ES import — 修复生产构建崩溃
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
- connectionStore: 2 处 require() → loadConversationStore() 异步预加载 + 闭包引用
- saasStore: 1 处 require() → await import()(logout 是 async)
- llm-service: 1 处 require() → 顶层 import(无循环依赖)
- streamStore: 移除重复动态导入,统一使用顶层 useConnectionStore
- tsc --noEmit 0 errors
|
2026-04-15 00:47:29 +08:00 |
|