Files
mnote/bugs/07-ai/process/7-20-page-ai-workflow-bypasses-hermes-tool-executor-v1.md
T
lix-2026 3311bd0366 chore: document architecture gaps and add dev hot reload
- add npm dev:hot wrapper using cargo-watch and page reload polling

- add mnote-web dev hot reload endpoint and coverage

- record current architecture review and tracked bug findings across realtime, tree, editor, and AI runtimes

Verification:

- node scripts/task-dev-hot-plan-test.js

- node --check scripts/dev-hot.js

- cargo test -p mnote-web dev_hot -- --nocapture
2026-05-17 23:09:56 +08:00

1.4 KiB

7-20 [process][bug] page_ai_workflow 绕过 Hermes tool executor / audit / toggle v1

发现时间:2026-05-17

状态:[process]

关联主线:07-ai

1. 问题定义

/api/page-ai/block-edit-workflow 仍是独立模型调用链:直接读取 Hermes profile、调用 chat/completions、解析模型 JSON,并直接调用 Rust 工具函数。

它没有通过 /api/hermes/tools/mnote/call 的工具执行壳,因此绕过了 tool toggle、audit、统一幂等和统一调用追踪。

2. 证据

3. 影响

  • 关闭或限制 mnote tool 时,该 fast-path 仍可能写入。
  • 工具调用审计与普通 Hermes run 不一致。
  • 幂等、dryRun、runId、toolCallId 等字段无法统一治理。

4. 建议修复

  • 将 fast-path 的工具写入改为调用统一 tool executor。
  • fast-path 只负责 prompt / plan,不直接执行写入函数。
  • 增加 smoke:当对应 tool disabled 时,page_ai_workflow 不得绕过限制写入。

5. 状态

已确认 route 级绕过统一执行壳,尚未修复。