|
|
f3a287bbd4
|
重构: audit第四批data_change收尾(strategy)
- 新建 audit/data_change.rs(50行 data_change_for_tool/emit_data_changed), audit/mod.rs 451→416(-35)
- pub(crate) re-export emit_data_changed(chat.rs super::super::audit + process_tool_calls裸名路径透明)
- F-09 per_conv保留(本批未触session/conv_id逻辑)
主代grep核验(不cargo避openai-split df-ai中间态): mod data_change/pub(crate)use + data_change.rs fn印证; agent隔离自验cargo 0+test 98
strategy: 单批1-2文件原子; audit/mod.rs余416(process_tool_calls主逻辑+build_write_file_diff/risk/truncate helper); audit四批拆分接近完成
git add指定(audit/*)
|
2026-06-19 04:35:41 +08:00 |
|
|
|
55bc1e1b23
|
重构: audit第三批cache + anthropic_compat拆分(strategy并行)
- audit 第三批: 新建 audit/cache.rs(151行 find_cached_high_risk_result/canonical_args_key/sort_object_keys/PENDING_APPROVAL_PLACEHOLDER), audit/mod.rs 586→451(-135); pub(crate) re-export, F-09 per_conv保留
- anthropic_compat 拆分: 新建 df-ai/anthropic_helpers.rs(223行 apply_anthropic_event + 5 struct + 2常量), anthropic_compat.rs 1036→842; Provider impl保留(impl块约束), 字段pub(crate)
主代兜底: cargo check --workspace 0 + test df-ai 119 + test devflow 98
strategy: 核心库自底向上, 单批1-2文件原子, impl块约束(Provider方法保留只抽纯函数/类型)
git add指定(audit/* + df-ai/*, 不含其他会话)
|
2026-06-19 04:31:19 +08:00 |
|
|
|
ed35c51a47
|
重构: AiChat第三批TopBar + audit第二批restore/finalize(strategy并行)
- AiChat 第三批: 新建 ai/TopBar.vue(499行, header+provider bar+切换bar+scoped样式), AiChat.vue 3128→2937(-191); props4+emits13+store共享; toast单一源emit provider-switched
- audit 第二批: 新建 audit/restore.rs(183行 restore_pending_approvals+2单测) + audit/finalize.rs(79行 audit_tool_call/audit_finalize), audit/mod.rs 812→586(-226); re-export路径透明, F-09 per_conv保留
主代兜底: cargo check --workspace 0 + test 98 + vue-tsc 0
strategy: 单批1-2文件原子, 并行(AiChat前端vue-tsc/audit后端cargo独立域)
git add指定(非-A, 避免覆盖其他会话改动)
|
2026-06-19 04:16:57 +08:00 |
|
|
|
e0ffd98223
|
重构: 拆audit.rs第一批reason helper(strategy)
- audit.rs → audit/mod.rs(959→812行) + 新建 audit/reason.rs(167行)
- 抽离 reason helper: resolve_project_label/resolve_task_label/build_approval_reason(3 fn自成闭包, pub(super))
- re-export 调用方零变更(commands::ai::audit::* 路径透明, 4处调用方+mod re-export核验)
- F-09 batch2 per_conv 保留(本批只搬 reason helper, conv_id路由不动)
主代兜底: cargo check --workspace 0 + test 98 + grep mod reason/use印证
strategy: 单批1-2文件原子; audit/mod.rs余812行(后续批restore/audit_finalize/find_cached)
|
2026-06-19 04:11:47 +08:00 |
|