退役 DirectProject 工具调用与回合流账本
Project CI / AI game creator shell Rust lane 2/2 (pull_request) Failing after 1m11s
Project CI / AI game creator shell Rust lane 1/2 (pull_request) Failing after 1m11s
Project CI / AI game creator shell Rust smoke (pull_request) Failing after 1m11s
Project CI / Backend tests (pull_request) Failing after 26s
Project CI / AI game creator shell Rust crates (pull_request) Successful in 1m42s
Project CI / Repository checks (pull_request) Failing after 27s
Project CI / Frontend tests (pull_request) Successful in 2m56s
Project CI / AI game creator shell web tests (pull_request) Successful in 2m42s
Project CI / Native shell tests (pull_request) Successful in 7m0s

- agent/direct_tool_calls.rs、agent/direct_turn_stream.rs:整体删除,agent.rs 去掉模块声明与导出
- direct_runtime/mod.rs:删 DirectToolCallCollector、回合流节流器与全部落盘/发射调用点,observer 只回填 update_active_turn
- codex_app_server/mod.rs:删 DirectCodexTurnObservation::ToolCall,AgentMessageSegment 结构体变体简化为元组变体,direct_tool_call_turn_id / direct_tool_call_now_ms 改名
- claude_code_cli.rs:删 tool_use / tool_result 采集分支与 DirectToolCall 构造
- main.rs、runtime_driver/entrypoints.rs:删 GameCreatorDirectTurnUpdateEvent 与 game-creator-direct-turn-update 事件,emit 收缩为 (status, activity)
- thread_manager/wire.rs:新增 direct_now_ms,替代随 direct_tool_calls 删除的时钟函数
- docs:ADR、工具调用卡片技术方案、DirectProject 聊天真相源收敛里程碑与实施计划、pitfalls 旧路径同步到当前状态,decision-log 新增 2026-09-30 退役条目
- 未修(另开):redact_absolute_path_tokens 的无语境绝对路径扫描仍会误伤 HTML 结束标签与嵌套 JSON 转义
- 验证:cargo test --bin genarrative-ai-game-creator-shell agent::(929 passed / 0 failed / 5 ignored)、npm run check:encoding、npm run check:doc-index、git diff --check
This commit is contained in:
2026-09-30 19:32:05 +08:00
parent 9ee34809be
commit 719db293d2
18 changed files with 328 additions and 2545 deletions
@@ -16,7 +16,7 @@
- **处理(本次)**:`sanitize_error_context` 改为 `split_inclusive('\n')` 逐段处理、原样保留行终止符(CRLF 仍归一成 LF,私钥块整行吞掉的旧口径不变)。逐段脱敏因此与整段脱敏同形,Markdown 结构不再依赖 delta 的切法。
- **仍未修**:`/` 开头的 delta 片段被判成绝对路径(上面 ②)。要修必须把「上一个字符」带进边界判定(正文增量可从 `direct_project_history` 的累计文本取,思考增量目前没有累计器),属于跨 delta 状态的取舍,本次未一并改。
- **判据/取证**:`cargo test --manifest-path apps/ai-game-creator-shell/src-tauri/Cargo.toml --bin genarrative-ai-game-creator-shell direct_thread_delta`——新增 `direct_thread_delta_sanitization_preserves_line_breaks` 钉住「逐段脱敏 == 整段脱敏」,去掉 `split_inclusive` 即红;真实文本的回归用渲染侧夹具复核(修复前 table/li/h2 全 0,修复后与整段脱敏一致:1 个 table / 3 个 th / 4 个 h2)。
- **关联**:`apps/ai-game-creator-shell/src-tauri/src/agent/codex_app_server/mod.rs`、`.../agent/generation/prompt_context.rs`、`.../agent/direct_thread_wire.rs`、`apps/ai-game-creator-shell/src/view/project-development/chat/conversation/directThreadChat.ts`、`#384`。
- **关联**:`apps/ai-game-creator-shell/src-tauri/src/agent/codex_app_server/mod.rs`、`.../agent/generation/prompt_context.rs`、`.../agent/thread_manager/wire.rs`、`apps/ai-game-creator-shell/src/view/project-development/chat/conversation/directThreadChat.ts`、`#384`。
## 2026-09-29 Game Agent 读工具被项目相对路径规则拦住