Commit Graph

2 Commits

Author SHA1 Message Date
Chiguyong bcfa4fb5f6 fix(iq): 补齐 PR #27 的 5 个实现缺口 + 2 个 P2 residuals
F1: 前端 autonomy_paused 事件处理
  - 新增 AutonomyPausedCard.vue 组件(reason + progress + resume 按钮)
  - chatStore/chatStream 接收 autonomy_paused 事件并渲染暂停卡片
  - ChatView 集成暂停卡片显示

F2: cleanup_expired 定时调用
  - episodic.py 的 prompt_reflection 记录 30 天过期清理接入

F3: SharedWorkspace.lock() TOCTOU 防护
  - _phase_executor.py 并行子任务写入用 lock() 防护
  - shared_workspace.py 补充锁实现

F4: retrieve_prompt_reflection KTD5 门控
  - react.py/reflexion.py 按 verify 二次失败/循环检测条件门控

F5: configs/agentkit.yaml.example 配置示例
  - 包含 dangerous_tools 配置示例

F6: resume Future 注册顺序消除竞态

F7: 用户拒绝危险工具不计入 _consecutive_failures

测试:112 个单元测试全部通过
2026-07-06 20:31:50 +08:00
Chiguyong 81a35dac27 feat(experts): U4 TeamOrchestrator parallel independent subtasks (R1-R5)
Add explicit support for parallel execution of dependency-free subtasks:
- TeamPlan.get_independent_subtasks(): returns phases with depends_on==[]
  (introspection entry — topological_sort already groups them in layer 0)
- TeamOrchestrator.MAX_INDEPENDENT_SUBTASKS=10: aligns with router.MAX_EXPERTS
- _rebalance_independent_subtasks(): when Lead over-decomposes (>10
  independent subtasks), re-decompose once with merge hint. Fallbacks:
  no gateway → keep original; LLM error → keep original; single-phase
  fallback → keep original (don't collapse 11→1); still over → return
  new (MAX_PHASES truncation handles it)

Tests: 15 new tests covering get_independent_subtasks, topological_sort
layer contract, SharedWorkspace path uniqueness, rebalance (5 paths),
and full execute() integration. Existing TeamOrchestrator tests pass.
2026-07-06 13:43:31 +08:00