Merge branch 'master' into fix/chat-state
Project CI / AI game creator shell Rust shard 1/4 (pull_request) Failing after 2m13s
Project CI / AI game creator shell Rust shard 3/4 (pull_request) Failing after 2m24s
Project CI / AI game creator shell Rust shard 2/4 (pull_request) Failing after 2m32s
Project CI / AI game creator shell Rust shard 4/4 (pull_request) Failing after 2m3s
Project CI / AI game creator shell Rust smoke (pull_request) Successful in 1m40s
Project CI / AI game creator shell Rust crates (pull_request) Successful in 2m11s
Project CI / Native shell tests (pull_request) Failing after 2m25s
Project CI / AI game creator shell web tests (pull_request) Failing after 1m14s
Project CI / Frontend tests (pull_request) Failing after 2m59s
Project CI / Repository checks (pull_request) Failing after 3m17s
Project CI / Backend tests (pull_request) Successful in 7m15s
Project CI / AI game creator shell Rust shard 1/4 (pull_request) Failing after 2m13s
Project CI / AI game creator shell Rust shard 3/4 (pull_request) Failing after 2m24s
Project CI / AI game creator shell Rust shard 2/4 (pull_request) Failing after 2m32s
Project CI / AI game creator shell Rust shard 4/4 (pull_request) Failing after 2m3s
Project CI / AI game creator shell Rust smoke (pull_request) Successful in 1m40s
Project CI / AI game creator shell Rust crates (pull_request) Successful in 2m11s
Project CI / Native shell tests (pull_request) Failing after 2m25s
Project CI / AI game creator shell web tests (pull_request) Failing after 1m14s
Project CI / Frontend tests (pull_request) Failing after 2m59s
Project CI / Repository checks (pull_request) Failing after 3m17s
Project CI / Backend tests (pull_request) Successful in 7m15s
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
# AGC 统一错误诊断与验收反馈实施计划
|
||||
|
||||
Version: 1.0
|
||||
Status: active
|
||||
Date: 2026-09-15
|
||||
Parent Milestone: `【里程碑】AGC统一错误诊断与验收反馈-2026-09-15.md`
|
||||
|
||||
## 修改边界
|
||||
|
||||
1. 新增 `agent/runtime_error.rs`,承载统一事件字段、code/stage 白名单、脱敏后的 public projection、项目错误 JSONL/sidecar 落库和 detail 读取边界。
|
||||
2. `direct_runtime.rs` 使用统一事件替代仅写 `failure.json` 的路径;失败 assistant 投影带稳定 ID,下一轮 prompt 注入最近失败事件摘要。
|
||||
3. `codex_app_server.rs` 将 failed turn、idle/hard timeout、transport close、invalid terminal 和 stderr tail 转成稳定事件字段;不公开原始 detail。
|
||||
4. `direct_tool_bridge.rs` 与 `direct_tools_mcp.rs` 让 attempt 由客户端回合状态约束,越界请求返回终态工具错误;不扩展重试预算。
|
||||
5. `direct_runtime.rs` 的素材扫描递归覆盖可执行源码模块,基于 manifest 身份和浏览器 URL 映射判定;补充模块引用回归测试。
|
||||
6. 前端读取后端 `publicText/detailRef`,在现有 Runtime 错误面板中加入详情入口;不在 React 侧重新分类错误。
|
||||
|
||||
## 实现顺序
|
||||
|
||||
先写统一事件模型和 Rust 单测,再接 direct failure/app-server/tool bridge,随后接 prompt/history 与前端详情,最后修素材验收和 attempt 生命周期。每一步保留原有脱敏和失败关闭行为。
|
||||
|
||||
## 验证命令
|
||||
|
||||
- `cargo fmt --check`
|
||||
- `cargo test --manifest-path apps/ai-game-creator-shell/src-tauri/Cargo.toml runtime_error direct_runtime codex_app_server direct_tool_bridge`
|
||||
- `npm run --prefix apps/ai-game-creator-shell typecheck`
|
||||
- `npm run check:encoding`
|
||||
- `git diff --check`
|
||||
- 必要时运行 AGC deterministic playable E2E;真实 Provider smoke 与浏览器双视口 smoke 单独报告。
|
||||
|
||||
## 风险与回滚
|
||||
|
||||
- 统一事件 schema 只新增项目内文件和对话投影,不修改已有 manifest、公开 API 或 SpacetimeDB schema。
|
||||
- 若前端详情读取失败,仍展示安全 `publicText`,不阻塞错误终态。
|
||||
- 若素材身份无法映射,继续失败关闭并记录明确 code,不回退为路径字符串通过。
|
||||
- 回滚可删除新事件写入和详情入口,保留旧 `failure.json` 读取兼容。
|
||||
@@ -0,0 +1,20 @@
|
||||
Version: 1
|
||||
Status: active
|
||||
Date: 2026-09-15
|
||||
Parent Spec: 【里程碑】AGC首页策划补全入口-2026-09-15.md
|
||||
|
||||
## 修改顺序
|
||||
|
||||
1. 在 `view/home/index.tsx` 增加本地复选框状态与入口切换清理。
|
||||
2. 将游戏勾选状态映射到既有 `ProjectStartMode`。
|
||||
3. 增加启动模式纯函数测试,覆盖模式分流;首页显示边界和切换清理作为后续组件测试补充项。
|
||||
|
||||
## 验证
|
||||
|
||||
- AGC 首页相关定向测试。
|
||||
- AGC 前端 typecheck。
|
||||
- `npm run check:encoding` 与 `git diff --check`。
|
||||
|
||||
## 当前验证边界
|
||||
|
||||
本次已交付测试覆盖 `planning` / `direct-build` 模式分流;“策划补全”复选框的显示边界及切换创作类型后的状态清理尚未有组件级自动化测试,需后续补充 `HomeView` 测试时完成。
|
||||
@@ -0,0 +1,39 @@
|
||||
# AGC 统一错误诊断与验收反馈
|
||||
|
||||
Version: 1.0
|
||||
Status: active
|
||||
Date: 2026-09-15
|
||||
Parent Spec: `docs/technical/【技术方案】AI游戏创作智能体App实施计划-2026-06-24.md` 的“2026-09-15 AGC 统一错误事件、诊断落库与验收反馈”
|
||||
|
||||
## 目标
|
||||
|
||||
让 DirectProject 和共享 Agent Runtime 对失败使用同一份安全、可追踪、可恢复的错误事件合同;用户追问失败原因时能够读取上一轮证据;构建与浏览器验收只依据真实源码、manifest 身份和运行时证据判断。
|
||||
|
||||
## 范围
|
||||
|
||||
- 统一错误事件模型与项目内诊断落库。
|
||||
- DirectProject 失败 assistant 投影、下一轮诊断上下文和前端详情入口。
|
||||
- app-server 终态/超时、内置 MCP 工具错误和试玩 attempt 上限的分类。
|
||||
- 游戏源码模块素材扫描、manifest 身份映射与浏览器观察映射。
|
||||
- 定向 Rust/前端回归和现有 AGC 运行时门禁。
|
||||
|
||||
## 不做
|
||||
|
||||
- 不改变 Provider、External Editor 或 app-server 的 wire 协议。
|
||||
- 不放宽项目写锁、凭据隔离、工具白名单或完成门安全边界。
|
||||
- 不迁移历史项目文件;旧诊断只读兼容,新增事件使用新 schema。
|
||||
- 不把原始 stderr、请求正文或绝对路径展示给用户。
|
||||
|
||||
## 验收标准
|
||||
|
||||
1. 任一 DirectProject 失败均生成统一事件、稳定 `eventId` 和有界诊断引用;落库失败不覆盖原始错误。
|
||||
2. 失败安全投影写入对话历史,下一轮能读取 `publicText / code / stage / detailRef`,不会因追问而自动试玩。
|
||||
3. 结构化 failed turn、idle/hard timeout、transport close、MCP 参数错误和 `other` 各有稳定 code 与 recoveryHint。
|
||||
4. `attempt` 由客户端按回合分配并有上限;越界调用不会让回合继续等待。
|
||||
5. `game/src` 下模块引用已登记素材、Vite dist 稳定映射和浏览器实际观察均能通过;未登记素材仍失败。
|
||||
6. 脱敏测试证明 Token、Cookie、URL/query、私钥、宿主绝对路径和 stderr 私密内容不会进入用户文本。
|
||||
|
||||
## 依赖
|
||||
|
||||
- 现有 `direct_project_history`、`runtime_state`、`codex_app_server`、`direct_tool_bridge` 与浏览器 validation 证据。
|
||||
- 现有 DirectProject 诊断 sidecar 和 manifest 资源身份。
|
||||
@@ -0,0 +1,20 @@
|
||||
Version: 1
|
||||
Status: active
|
||||
Date: 2026-09-15
|
||||
Parent Spec: AGC 首页与 Agent Runtime 入口
|
||||
|
||||
## 范围
|
||||
|
||||
在首页“做游戏”输入框下增加“策划补全”复选框;勾选后复用现有 `planning` 启动模式进入策划 Agent Runtime。
|
||||
|
||||
## 验收标准
|
||||
|
||||
- 仅“做游戏”显示复选框。
|
||||
- 勾选时提交 `planning`,未勾选时提交 `direct-build`。
|
||||
- “做方案”原有 `planning` 行为保持不变。
|
||||
- 切换到其它创作类型时清除游戏专属勾选状态。
|
||||
|
||||
## 不做项
|
||||
|
||||
- 不新增 runtime 类型、后端接口或持久化字段。
|
||||
- 不改变现有策划 runtime 内部流程。
|
||||
Reference in New Issue
Block a user